about summary refs log tree commit diff
path: root/stdio-common
diff options
context:
space:
mode:
authorThomas Schwinge <thomas@codesourcery.com>2013-05-26 21:59:24 +0200
committerThomas Schwinge <thomas@codesourcery.com>2013-05-26 21:59:24 +0200
commit528c24058fb100fb27fe5c211b92be84c67a6659 (patch)
tree49f660e44e114455b7375abd0ebaaedd0694299a /stdio-common
parent07b4c13d0be4814ef10bbfbfd68db604978aa0e5 (diff)
downloadglibc-528c24058fb100fb27fe5c211b92be84c67a6659.tar.gz
glibc-528c24058fb100fb27fe5c211b92be84c67a6659.tar.xz
glibc-528c24058fb100fb27fe5c211b92be84c67a6659.zip
* stdio-common/bug26.c (main): Correct fscanf template.
Fixup for commit 6ecec3b616aeaf121c68c1053cd17fdcf0cdb5a2.
Diffstat (limited to 'stdio-common')
-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.");