]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Update.
authorUlrich Drepper <drepper@redhat.com>
Wed, 13 May 1998 16:25:59 +0000 (16:25 +0000)
committerUlrich Drepper <drepper@redhat.com>
Wed, 13 May 1998 16:25:59 +0000 (16:25 +0000)
* stdlib/tst-strtod.c: Add test for -0.0.

ChangeLog
stdlib/tst-strtod.c

index ef83e4d57f46cfaa7e31e7c558b5949aff0fe3e0..73b3bf146e1236bbb174d85dc87c79fa40874860 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 1998-05-13  Ulrich Drepper  <drepper@cygnus.com>
 
+       * stdlib/tst-strtod.c: Add test for -0.0.
+
        * io/ftwtest-sh: Prevent tests from being run by root.
 
        * wcsmbs/wcsmbsload.c (extract_charset_name): Fix silly bugs in
index 3cc907f2ac6df7ddade2e1909f92d665df8d60f4..bfc2481589041d5d3c72335ec7e57ac45f3622b8 100644 (file)
@@ -47,6 +47,7 @@ static void expand __P ((char *dst, int c));
 int
 main (int argc, char ** argv)
 {
+  char buf[100];
   register const struct ltest *lt;
   char *ep;
   int status = 0;
@@ -83,6 +84,13 @@ main (int argc, char ** argv)
        }
     }
 
+  sprintf (buf, "%f", strtod ("-0.0", NULL));
+  if (strcmp (buf, "-0.000000") != 0)
+    {
+      printf ("  strtod (\"-0.0\', NULL) returns \"%s\"\n", buf);
+      status = 1;
+    }
+
   exit (status ? EXIT_FAILURE : EXIT_SUCCESS);
 }