[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[commits] r6436 - in /fsf/trunk/libc: ./ localedata/ localedata/locales/ posix/ stdlib/



Author: eglibc
Date: Thu Jun 26 00:05:04 2008
New Revision: 6436

Log:
Import glibc-mainline for 2008-06-26

Modified:
    fsf/trunk/libc/ChangeLog
    fsf/trunk/libc/configure
    fsf/trunk/libc/configure.in
    fsf/trunk/libc/localedata/ChangeLog
    fsf/trunk/libc/localedata/locales/es_CR
    fsf/trunk/libc/localedata/locales/fi_FI
    fsf/trunk/libc/localedata/tst-strptime.c
    fsf/trunk/libc/posix/tst-regex.c
    fsf/trunk/libc/stdlib/canonicalize.c
    fsf/trunk/libc/stdlib/tst-setcontext.c

Modified: fsf/trunk/libc/ChangeLog
==============================================================================
--- fsf/trunk/libc/ChangeLog (original)
+++ fsf/trunk/libc/ChangeLog Thu Jun 26 00:05:04 2008
@@ -1,3 +1,30 @@
+2008-06-25  Ulrich Drepper  <drepper@xxxxxxxxxx>
+
+	[BZ #6654]
+	* stdlib/canonicalize.c (__realpath): readlink can write too much
+	into the buffer on platforms without PATH_MAX.
+
+2008-06-17  Carlos O'Donell  <carlos@xxxxxxxxxxxxxxxx>
+
+	[BZ #6653]
+	* posix/tst-regex.c (main): Rename to...
+	(do_test): ... this. Remove cmdline option processing.
+	(TIMEOUT): Define.
+	(TEST_FUNCTION): Define.
+	(CMDLINE_OPTIONS): Define.
+
+2008-06-25  Ulrich Drepper  <drepper@xxxxxxxxxx>
+
+	[BZ #5210]
+	* configure.in: Add -Werror to -fstack-protector test to catch
+	unsupported architectures.
+	Patch by Gilles Esponasse <g.esp@xxxxxxx>.
+
+2008-06-17  Joseph Myers  <joseph@xxxxxxxxxxxxxxxx>
+
+	* stdlib/tst-setcontext.c: Set back_in_main before exit if
+	getcontext returns ENOSYS.
+
 2008-06-18  Ulrich Drepper  <drepper@xxxxxxxxxx>
 
 	* nscd/connections.c (main_loop_poll): Fix test for read error.

Modified: fsf/trunk/libc/configure
==============================================================================
--- fsf/trunk/libc/configure (original)
+++ fsf/trunk/libc/configure Thu Jun 26 00:05:04 2008
@@ -6451,7 +6451,7 @@
 int foo;
 main () { return 0;}
 EOF
-if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -fstack-protector
+if { ac_try='${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -Werror -fstack-protector
 			    -o conftest conftest.c 1>&5'
   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
   (eval $ac_try) 2>&5

Modified: fsf/trunk/libc/configure.in
==============================================================================
--- fsf/trunk/libc/configure.in (original)
+++ fsf/trunk/libc/configure.in Thu Jun 26 00:05:04 2008
@@ -1638,7 +1638,7 @@
 int foo;
 main () { return 0;}
 EOF
-if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -fstack-protector
+if AC_TRY_COMMAND([${CC-cc} $CFLAGS $CPPFLAGS $LDFLAGS -Werror -fstack-protector
 			    -o conftest conftest.c 1>&AS_MESSAGE_LOG_FD])
 then
   libc_cv_ssp=yes

Modified: fsf/trunk/libc/localedata/ChangeLog
==============================================================================
--- fsf/trunk/libc/localedata/ChangeLog (original)
+++ fsf/trunk/libc/localedata/ChangeLog Thu Jun 26 00:05:04 2008
@@ -1,3 +1,14 @@
+2008-06-25  Ulrich Drepper  <drepper@xxxxxxxxxx>
+
+	* tst-strptime.c (do_test): Add test for parsing era year
+	representation.
+
+	[BZ #5911]
+	* locales/es_CR: Define first_weekday and first_workday.
+
+	[BZ #5814]
+	* locales/fi_FI: Fix separator for hours, minutes, and seconds.
+
 2008-06-24  Ulrich Drepper  <drepper@xxxxxxxxxx>
 
 	* locales/iso14651_t1_common: Add support for Gurumukhi script.

Modified: fsf/trunk/libc/localedata/locales/es_CR
==============================================================================
--- fsf/trunk/libc/localedata/locales/es_CR (original)
+++ fsf/trunk/libc/localedata/locales/es_CR Thu Jun 26 00:05:04 2008
@@ -113,6 +113,8 @@
 date_fmt	"<U0025><U0061><U0020><U0025><U0062><U0020><U0025><U0065>/
 <U0020><U0025><U0048><U003A><U0025><U004D><U003A><U0025><U0053><U0020>/
 <U0025><U005A><U0020><U0025><U0059>"
+first_weekday 1
+first_workday 2
 END LC_TIME
 
 LC_PAPER

Modified: fsf/trunk/libc/localedata/locales/fi_FI
==============================================================================
--- fsf/trunk/libc/localedata/locales/fi_FI (original)
+++ fsf/trunk/libc/localedata/locales/fi_FI Thu Jun 26 00:05:04 2008
@@ -193,13 +193,15 @@
          "<U006D><U0061><U0072><U0072><U0061><U0073><U006B><U0075><U0075>";/
          "<U006A><U006F><U0075><U006C><U0075><U006B><U0075><U0075>"
 d_t_fmt  "<U0025><U0061><U0020><U0025><U0065><U002E><U0020><U0025><U0042>/
-<U0074><U0061><U0020><U0025><U0059><U0020><U0025><U0054>"
+<U0074><U0061><U0020><U0025><U0059><U0020><U0025><U0048><U002E><U0025>/
+<U004D><U002E><U0025><U0053>"
 d_fmt    "<U0025><U0064><U002E><U0025><U006D><U002E><U0025><U0059>"
-t_fmt    "<U0025><U0054>"
+t_fmt    "<U0025><U0048><U002E><U0025><U004D><U002E><U0025><U0053>"
 am_pm    "";""
 t_fmt_ampm  ""
 date_fmt       "<U0025><U0061><U0020><U0025><U002D><U0064><U002E><U0025>/
-<U002D><U006D><U002E><U0025><U0059><U0020><U0025><U0054><U0020><U0025><U007A>"
+<U002D><U006D><U002E><U0025><U0059><U0020><U0025><U0048><U002E><U0025>/
+<U004D><U002E><U0025><U0053><U0020><U0025><U007A>"
 first_weekday 2 % Monday
 first_workday 2 % Monday
 END LC_TIME

Modified: fsf/trunk/libc/localedata/tst-strptime.c
==============================================================================
--- fsf/trunk/libc/localedata/tst-strptime.c (original)
+++ fsf/trunk/libc/localedata/tst-strptime.c Thu Jun 26 00:05:04 2008
@@ -1,22 +1,43 @@
 #include <locale.h>
 #include <time.h>
 #include <stdio.h>
+#include <string.h>
 
 static int
 do_test (void)
 {
+  int result = 0;
+
   if (setlocale (LC_ALL, "vi_VN.TCVN5712-1") == NULL)
     {
       puts ("cannot set locale");
       return 1;
     }
   struct tm tm;
+  memset (&tm, '\0', sizeof (tm));
   /* This is November in Vietnamese encoded using TCVN5712-1.  */
   static const char s[] = "\
-\x54\x68\xb8\x6e\x67\x20\x6d\xad\xea\x69\x20\x6d\xe9\x74";
+\x54\x68\xb8\x6e\x67\x20\x6d\xad\xea\x69\x20\x6d\xe9\x74\0";
   char *r = strptime (s, "%b", &tm);
   printf ("r = %p, r-s = %tu, tm.tm_mon = %d\n", r, r - s, tm.tm_mon);
-  return r == NULL || r - s != 14 || tm.tm_mon != 10;
+  result = r == NULL || r - s != 14 || tm.tm_mon != 10;
+
+  if (setlocale (LC_ALL, "ja_JP.UTF-8") == NULL)
+    {
+      puts ("cannot set locale");
+      return 1;
+    }
+  static const char s2[] = "\
+\x32\x35\x20\x30\x36\x20\xe5\xb9\xb3\xe6\x88\x90\x32\x30\0";
+  memset (&tm, '\0', sizeof (tm));
+  r = strptime (s2, "%d %m %EC%Ey", &tm);
+  printf ("\
+r = %p, r-s2 = %tu, tm.tm_mday = %d, tm.tm_mon = %d, tm.tm_year = %d\n",
+	  r, r - s2, tm.tm_mday, tm.tm_mon, tm.tm_year);
+  result |= (r == NULL || r - s2 != 14 || tm.tm_mday != 25 || tm.tm_mon != 5
+	     || tm.tm_year != 108);
+
+  return result;
 }
 
 #define TEST_FUNCTION do_test ()

Modified: fsf/trunk/libc/posix/tst-regex.c
==============================================================================
--- fsf/trunk/libc/posix/tst-regex.c (original)
+++ fsf/trunk/libc/posix/tst-regex.c Thu Jun 26 00:05:04 2008
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001, 2003 Free Software Foundation, Inc.
+/* Copyright (C) 2001, 2003, 2008 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -55,8 +55,8 @@
 			       size_t memlen, int icase, int expected);
 
 
-int
-main (int argc, char *argv[])
+static int
+do_test (void)
 {
   const char *file;
   int fd;
@@ -66,15 +66,8 @@
   char *outmem;
   size_t inlen;
   size_t outlen;
-  static const struct option options[] =
-    {
-      {"timing",no_argument,	&timing,	1 },
-      {NULL,	0,		NULL,		0 }
-    };
 
   mtrace ();
-
-  while (getopt_long (argc, argv, "", options, NULL) >= 0);
 
   /* Make the content of the file available in memory.  */
   file = "../ChangeLog.8";
@@ -506,3 +499,10 @@
      expect.  */
   return cnt != expected;
 }
+
+/* If --timing is used we will need a larger timout.  */
+#define TIMEOUT 50
+#define CMDLINE_OPTIONS \
+   {"timing", no_argument, &timing, 1 },
+#define TEST_FUNCTION do_test ()
+#include "../test-skeleton.c"

Modified: fsf/trunk/libc/stdlib/canonicalize.c
==============================================================================
--- fsf/trunk/libc/stdlib/canonicalize.c (original)
+++ fsf/trunk/libc/stdlib/canonicalize.c Thu Jun 26 00:05:04 2008
@@ -1,5 +1,5 @@
 /* Return the canonical absolute name of a given file.
-   Copyright (C) 1996-2002, 2004, 2005, 2006 Free Software Foundation, Inc.
+   Copyright (C) 1996-2002,2004,2005,2006,2008 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -173,7 +173,7 @@
 		  goto error;
 		}
 
-	      n = __readlink (rpath, buf, path_max);
+	      n = __readlink (rpath, buf, path_max - 1);
 	      if (n < 0)
 		goto error;
 	      buf[n] = '\0';

Modified: fsf/trunk/libc/stdlib/tst-setcontext.c
==============================================================================
--- fsf/trunk/libc/stdlib/tst-setcontext.c (original)
+++ fsf/trunk/libc/stdlib/tst-setcontext.c Thu Jun 26 00:05:04 2008
@@ -150,7 +150,10 @@
   if (getcontext (&ctx[1]) != 0)
     {
       if (errno == ENOSYS)
-	exit (0);
+	{
+	  back_in_main = 1;
+	  exit (0);
+	}
 
       printf ("%s: getcontext: %m\n", __FUNCTION__);
       exit (1);