summaryrefslogtreecommitdiffstats
path: root/lib/libc/stdio/vfscanf.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/stdio/vfscanf.c')
-rw-r--r--lib/libc/stdio/vfscanf.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/lib/libc/stdio/vfscanf.c b/lib/libc/stdio/vfscanf.c
index 6a05343..118323f 100644
--- a/lib/libc/stdio/vfscanf.c
+++ b/lib/libc/stdio/vfscanf.c
@@ -56,9 +56,7 @@ __FBSDID("$FreeBSD$");
#include "libc_private.h"
#include "local.h"
-#define FLOATING_POINT
-
-#ifdef FLOATING_POINT
+#ifndef NO_FLOATING_POINT
#include <locale.h>
#endif
@@ -254,7 +252,7 @@ literal:
base = 16;
break;
-#ifdef FLOATING_POINT
+#ifndef NO_FLOATING_POINT
case 'A': case 'E': case 'F': case 'G':
case 'a': case 'e': case 'f': case 'g':
c = CT_FLOAT;
@@ -768,7 +766,7 @@ literal:
nconversions++;
break;
-#ifdef FLOATING_POINT
+#ifndef NO_FLOATING_POINT
case CT_FLOAT:
/* scan a floating point number as if by strtod */
if (width == 0 || width > sizeof(buf) - 1)
@@ -793,7 +791,7 @@ literal:
nread += width;
nconversions++;
break;
-#endif /* FLOATING_POINT */
+#endif /* !NO_FLOATING_POINT */
}
}
input_failure:
@@ -915,7 +913,7 @@ doswitch:
/* NOTREACHED */
}
-#ifdef FLOATING_POINT
+#ifndef NO_FLOATING_POINT
static int
parsefloat(FILE *fp, char *buf, char *end)
{
OpenPOWER on IntegriCloud