2003-03-04 Roland McGrath <roland@redhat.com>
authorroland <roland>
Wed, 5 Mar 2003 03:02:26 +0000 (03:02 +0000)
committerroland <roland>
Wed, 5 Mar 2003 03:02:26 +0000 (03:02 +0000)
* posix/confstr.c (confstr): Correct STRING_LEN values for
_CS_GNU_LIBC_VERSION and _CS_GNU_LIBPTHREAD_VERSION, add missing
break.  Reported by Alexandre Julliard <julliard@winehq.com>.

posix/confstr.c

index bc3c8b8..212ec72 100644 (file)
@@ -143,12 +143,13 @@ confstr (name, buf, len)
 
     case _CS_GNU_LIBC_VERSION:
       string = "glibc " VERSION;
-      string_len = strlen (string);
+      string_len = sizeof ("glibc " VERSION);
+      break;
 
     case _CS_GNU_LIBPTHREAD_VERSION:
 #ifdef LIBPTHREAD_VERSION
       string = LIBPTHREAD_VERSION;
-      string_len = strlen (string);
+      string_len = sizeof LIBPTHREAD_VERSION;
       break;
 #else
       /* No thread library.  */