Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libc/gen Add support for Windows I{32, 64} formats from J...



details:   https://anonhg.NetBSD.org/src/rev/96f211718804
branches:  trunk
changeset: 343044:96f211718804
user:      christos <christos%NetBSD.org@localhost>
date:      Wed Jan 20 15:43:05 2016 +0000

description:
Add support for Windows I{32,64} formats from Jason Hood via file(1).

diffstat:

 lib/libc/gen/fmtcheck.c |  21 +++++++++++++++++++--
 1 files changed, 19 insertions(+), 2 deletions(-)

diffs (42 lines):

diff -r 45f6cb1bdc2e -r 96f211718804 lib/libc/gen/fmtcheck.c
--- a/lib/libc/gen/fmtcheck.c   Wed Jan 20 15:31:55 2016 +0000
+++ b/lib/libc/gen/fmtcheck.c   Wed Jan 20 15:43:05 2016 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: fmtcheck.c,v 1.9 2014/06/14 08:18:24 apb Exp $ */
+/*     $NetBSD: fmtcheck.c,v 1.10 2016/01/20 15:43:05 christos Exp $   */
 
 /*-
  * Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
 
 #include <sys/cdefs.h>
 #if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: fmtcheck.c,v 1.9 2014/06/14 08:18:24 apb Exp $");
+__RCSID("$NetBSD: fmtcheck.c,v 1.10 2016/01/20 15:43:05 christos Exp $");
 #endif
 
 #include "namespace.h"
@@ -101,6 +101,23 @@
                f++;
                longdouble = 1;
                break;
+#ifdef WIN32
+       case 'I':
+               f++;
+               if (!*f) RETURN(pf,f,FMTCHECK_UNKNOWN);
+               if (*f == '3' && f[1] == '2') {
+                       f += 2;
+               } else if (*f == '6' && f[1] == '4') {
+                       f += 2;
+                       quad = 1;
+               }
+#ifdef _WIN64
+               else {
+                       quad = 1;
+               }
+#endif
+               break;
+#endif
        default:
                break;
        }



Home | Main Index | Thread Index | Old Index