summaryrefslogtreecommitdiff
path: root/stdio-common/bug26.c
diff options
context:
space:
mode:
Diffstat (limited to 'stdio-common/bug26.c')
-rw-r--r--stdio-common/bug26.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/stdio-common/bug26.c b/stdio-common/bug26.c
index a4c6bce939..cc54b96418 100644
--- a/stdio-common/bug26.c
+++ b/stdio-common/bug26.c
@@ -28,8 +28,9 @@ main (void)
char s[] = "+.e";
f = fmemopen (s, strlen (s), "r");
- /* This should fail to parse a float and leave 'e' in the input. */
- lost |= (fscanf (f, "%f", &d) != 0);
+ /* This should fail to parse a floating-point number, and leave 'e' in the
+ input. */
+ lost |= (fscanf (f, "%lf", &d) != 0);
c = fgetc (f);
lost |= c != 'e';
puts (lost ? "Test FAILED!" : "Test succeeded.");