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

[commits] r14037 - in /fsf/trunk/libc: ./ elf/ locale/programs/ malloc/ resolv/ shadow/ sysdeps/posix/ sysdeps/unix/sysv/linux/bits/ s...



Author: eglibc
Date: Mon May 30 00:03:26 2011
New Revision: 14037

Log:
Import glibc-mainline for 2011-05-30

Modified:
    fsf/trunk/libc/ChangeLog
    fsf/trunk/libc/NEWS
    fsf/trunk/libc/elf/Makefile
    fsf/trunk/libc/elf/rtld.c
    fsf/trunk/libc/locale/programs/locarchive.c
    fsf/trunk/libc/malloc/malloc.h
    fsf/trunk/libc/resolv/res_init.c
    fsf/trunk/libc/shadow/sgetspent_r.c
    fsf/trunk/libc/sysdeps/posix/getaddrinfo.c
    fsf/trunk/libc/sysdeps/unix/sysv/linux/bits/siginfo.h
    fsf/trunk/libc/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h
    fsf/trunk/libc/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
    fsf/trunk/libc/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h

Modified: fsf/trunk/libc/ChangeLog
==============================================================================
--- fsf/trunk/libc/ChangeLog (original)
+++ fsf/trunk/libc/ChangeLog Mon May 30 00:03:26 2011
@@ -1,3 +1,42 @@
+2011-05-30  Ulrich Drepper  <drepper@xxxxxxxxx>
+
+	* elf/rtld.c (dl_main): Don't allow the loader to load itself.
+
+2011-05-29  Ulrich Drepper  <drepper@xxxxxxxxx>
+
+	[BZ #12350]
+	* sysdeps/posix/getaddrinfo.c (gethosts): Restore only RES_USE_IENT6
+	bit from old_res_options.
+	(gaih_inet): Likewise.
+
+	[BZ #11099]
+	* shadow/sgetspent_r.c (LINE_PARSER): Interpret nymeric field values
+	as signed.
+
+	* resolv/res_init.c (res_setoptions): Make the code more compact.
+
+	[BZ #11558]
+	* resolv/res_init.c (res_setoptions): Recognize use-vc option and
+	set RES_USEVC.
+
+	[BZ #11634]
+	* elf/Makefile (tests): Don't add tst-audit[67] without working -mavx.
+
+	* malloc/malloc.h: Mark malloc hook variables as deprecated.
+
+	[BZ #11781]
+	* malloc/malloc.h: Declare malloc hook variables as volatile.
+
+	* locale/programs/locarchive.c (add_locale_to_archive): Fix typo
+	in last patch.
+
+	[BZ #11799]
+	* sysdeps/unix/sysv/linux/bits/siginfo.h (SI_USER): Don't mention
+	SI_USER in the comment.
+	* sysdeps/unix/sysv/linux/s390/bits/siginfo.h: Likewise.
+	* sysdeps/unix/sysv/linux/sparc/bits/siginfo.h: Likewise.
+	* sysdeps/unix/sysv/linux/ia64/bits/siginfo.h: Likewise.
+
 2011-05-28  Ulrich Drepper  <drepper@xxxxxxxxx>
 
 	[BZ #12811]
@@ -2492,6 +2531,7 @@
 
 2010-07-06  Andreas Schwab  <schwab@xxxxxxxxxx>
 
+	[BZ #11577]
 	* elf/dl-version.c (match_symbol): Don't pass NULL occation to
 	dl_signal_cerror.
 

Modified: fsf/trunk/libc/NEWS
==============================================================================
--- fsf/trunk/libc/NEWS (original)
+++ fsf/trunk/libc/NEWS Mon May 30 00:03:26 2011
@@ -1,4 +1,4 @@
-GNU C Library NEWS -- history of user-visible changes.  2011-5-28
+GNU C Library NEWS -- history of user-visible changes.  2011-5-29
 Copyright (C) 1992-2009, 2010, 2011 Free Software Foundation, Inc.
 See the end for copying conditions.
 
@@ -9,15 +9,16 @@
 
 * The following bugs are resolved with this release:
 
-  386, 6420, 7101, 9730, 9732, 9809, 10138, 10149, 10157, 11257, 11258,
-  11487, 11532, 11578, 11653, 11668, 11697, 11724, 11820, 11837, 11857,
-  11869, 11892, 11895, 11901, 11945, 11947, 11952, 11987, 12052, 12083,
-  12158, 12178, 12200, 12346, 12393, 12420, 12432, 12445, 12449, 12453,
-  12454, 12460, 12469, 12489, 12509, 12510, 12511, 12518, 12527, 12541,
-  12545, 12551, 12582, 12583, 12587, 12597, 12601, 12611, 12625, 12626,
-  12631, 12650, 12653, 12655, 12660, 12671, 12681, 12685, 12711, 12713,
-  12714, 12717, 12723, 12724, 12734, 12738, 12746, 12766, 12775, 12777,
-  12782, 12788, 12792, 12795, 12811, 12813, 12814
+  386, 6420, 7101, 9730, 9732, 9809, 10138, 10149, 10157, 11099, 11257,
+  11258, 11487, 11532, 11558, 11578, 11634, 11653, 11668, 11697, 11724,
+  11781, 11799, 11820, 11837, 11857, 11869, 11892, 11895, 11901, 11945,
+  11947, 11952, 11987, 12052, 12083, 12158, 12178, 12200, 12346, 12350,
+  12393, 12420, 12432, 12445, 12449, 12453, 12454, 12460, 12469, 12489,
+  12509, 12510, 12511, 12518, 12527, 12541, 12545, 12551, 12582, 12583,
+  12587, 12597, 12601, 12611, 12625, 12626, 12631, 12650, 12653, 12655,
+  12660, 12671, 12681, 12685, 12711, 12713, 12714, 12717, 12723, 12724,
+  12734, 12738, 12746, 12766, 12775, 12777, 12782, 12788, 12792, 12795,
+  12811, 12813, 12814
 
 * The RPC implementation in libc is obsoleted.  Old programs keep working
   but new programs cannot be linked with the routines in libc anymore.
@@ -39,16 +40,21 @@
 
 * New program sotruss to trace calls through PLTs
   Implemented by Ulrich Drepper.
+
+* The malloc hook implementation is marked deprecated and will be removed
+  from the default implementation in the next version.  The design never
+  worked ever since the introduction of threads.  Even programs which do
+  not create threads themselves can use multiple threads created internally.
 
 Version 2.13
 
 * The following bugs are resolved with this release:
 
-  3268, 6812, 7066, 10085, 10484, 10563, 10851, 11149, 11155, 11611, 11640,
-  11655, 11701, 11840, 11856, 11883, 11903, 11904, 11968, 11979, 12005,
-  12037, 12067, 12077, 12078, 12092, 12093, 12107, 12108, 12113, 12140,
-  12159, 12167, 12191, 12194, 12201, 12204, 12205, 12207, 12348, 12378,
-  12394, 12397
+  3268, 6812, 7066, 10085, 10484, 10563, 10851, 11149, 11155, 11577, 11611,
+  11640, 11655, 11701, 11840, 11856, 11883, 11903, 11904, 11968, 11979,
+  12005, 12037, 12067, 12077, 12078, 12092, 12093, 12107, 12108, 12113,
+  12140, 12159, 12167, 12191, 12194, 12201, 12204, 12205, 12207, 12348,
+  12378, 12394, 12397
 
 * New Linux interfaces: prlimit, prlimit64, fanotify_init, fanotify_mark
 

Modified: fsf/trunk/libc/elf/Makefile
==============================================================================
--- fsf/trunk/libc/elf/Makefile (original)
+++ fsf/trunk/libc/elf/Makefile Mon May 30 00:03:26 2011
@@ -233,7 +233,10 @@
 tests-execstack-yes = tst-execstack tst-execstack-needed tst-execstack-prog
 endif
 ifeq (x86_64,$(config-machine))
-tests += tst-audit3 tst-audit4 tst-audit5 tst-audit6 tst-audit7
+tests += tst-audit3 tst-audit4 tst-audit5
+ifeq (yes,$(config-cflags-avx))
+tests += tst-audit6 tst-audit7
+endif
 endif
 endif
 tests: $(objpfx)tst-leaks1-mem $(objpfx)noload-mem

Modified: fsf/trunk/libc/elf/rtld.c
==============================================================================
--- fsf/trunk/libc/elf/rtld.c (original)
+++ fsf/trunk/libc/elf/rtld.c Mon May 30 00:03:26 2011
@@ -1075,6 +1075,14 @@
 
       /* Now the map for the main executable is available.  */
       main_map = GL(dl_ns)[LM_ID_BASE]._ns_loaded;
+
+      if (GL(dl_rtld_map).l_info[DT_SONAME] != NULL
+	  && main_map->l_info[DT_SONAME] != NULL
+	  && strcmp ((const char *) D_PTR (&GL(dl_rtld_map), l_info[DT_STRTAB])
+		     + GL(dl_rtld_map).l_info[DT_SONAME]->d_un.d_val,
+		     (const char *) D_PTR (main_map, l_info[DT_STRTAB])
+		     + main_map->l_info[DT_SONAME]->d_un.d_val) == 0)
+	_dl_fatal_printf ("loader cannot load itself\n");
 
       phdr = main_map->l_phdr;
       phnum = main_map->l_phnum;

Modified: fsf/trunk/libc/locale/programs/locarchive.c
==============================================================================
--- fsf/trunk/libc/locale/programs/locarchive.c (original)
+++ fsf/trunk/libc/locale/programs/locarchive.c Mon May 30 00:03:26 2011
@@ -1210,7 +1210,7 @@
 						     &rhs_territory,
 						     &rhs_codeset,
 						     &rhs_normalized_codeset);
-		    if (rhs_mask == 1)
+		    if (rhs_mask == -1)
 		      {
 			result = -1;
 			goto out;

Modified: fsf/trunk/libc/malloc/malloc.h
==============================================================================
--- fsf/trunk/libc/malloc/malloc.h (original)
+++ fsf/trunk/libc/malloc/malloc.h Mon May 30 00:03:26 2011
@@ -1,5 +1,5 @@
 /* Prototypes and definition for malloc implementation.
-   Copyright (C) 1996, 1997, 1999, 2000, 2002-2004, 2005, 2007, 2009
+   Copyright (C) 1996, 1997, 1999, 2000, 2002-2004, 2005, 2007, 2009, 2011
    Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
@@ -37,10 +37,20 @@
    functions.  */
 # define __MALLOC_PMT(args)	args
 
+# ifdef _LIBC
+#  define __MALLOC_HOOK_VOLATILE
+#  define __MALLOC_DEPRECATED
+# else
+#  define __MALLOC_HOOK_VOLATILE __volatile
+#  define __MALLOC_DEPRECATED __attribute_deprecated__
+# endif
+
 #else	/* Not GCC.  */
 
 # define __MALLOC_P(args)	args
 # define __MALLOC_PMT(args)	args
+# define __MALLOC_HOOK_VOLATILE
+# define __MALLOC_DEPRECATED __attribute_deprecated__
 
 #endif	/* GCC.  */
 
@@ -48,50 +58,49 @@
 __BEGIN_DECLS
 
 /* Allocate SIZE bytes of memory.  */
-extern void *malloc __MALLOC_P ((size_t __size)) __attribute_malloc__ __wur;
+extern void *malloc (size_t __size) __THROW __attribute_malloc__ __wur;
 
 /* Allocate NMEMB elements of SIZE bytes each, all initialized to 0.  */
-extern void *calloc __MALLOC_P ((size_t __nmemb, size_t __size))
-       __attribute_malloc__ __wur;
+extern void *calloc (size_t __nmemb, size_t __size)
+     __THROW __attribute_malloc__ __wur;
 
 /* Re-allocate the previously allocated block in __ptr, making the new
    block SIZE bytes long.  */
 /* __attribute_malloc__ is not used, because if realloc returns
    the same pointer that was passed to it, aliasing needs to be allowed
    between objects pointed by the old and new pointers.  */
-extern void *realloc __MALLOC_P ((void *__ptr, size_t __size))
-       __attribute_warn_unused_result__;
+extern void *realloc (void *__ptr, size_t __size)
+     __THROW __attribute_warn_unused_result__;
 
 /* Free a block allocated by `malloc', `realloc' or `calloc'.  */
-extern void free __MALLOC_P ((void *__ptr));
+extern void free (void *__ptr) __THROW;
 
 /* Free a block allocated by `calloc'. */
-extern void cfree __MALLOC_P ((void *__ptr));
+extern void cfree (void *__ptr) __THROW;
 
 /* Allocate SIZE bytes allocated to ALIGNMENT bytes.  */
-extern void *memalign __MALLOC_P ((size_t __alignment, size_t __size))
-       __attribute_malloc__ __wur;
+extern void *memalign (size_t __alignment, size_t __size)
+     __THROW __attribute_malloc__ __wur;
 
 /* Allocate SIZE bytes on a page boundary.  */
-extern void *valloc __MALLOC_P ((size_t __size))
-       __attribute_malloc__ __wur;
+extern void *valloc (size_t __size) __THROW __attribute_malloc__ __wur;
 
 /* Equivalent to valloc(minimum-page-that-holds(n)), that is, round up
    __size to nearest pagesize. */
-extern void * pvalloc __MALLOC_P ((size_t __size))
-       __attribute_malloc__ __wur;
+extern void * pvalloc (size_t __size) __THROW __attribute_malloc__ __wur;
 
 /* Underlying allocation function; successive calls should return
    contiguous pieces of memory.  */
-extern void *(*__morecore) __MALLOC_PMT ((ptrdiff_t __size));
+extern void *(*__morecore) (ptrdiff_t __size);
 
 /* Default value of `__morecore'.  */
-extern void *__default_morecore __MALLOC_P ((ptrdiff_t __size))
-       __attribute_malloc__;
+extern void *__default_morecore (ptrdiff_t __size)
+     __THROW __attribute_malloc__;
 
 /* SVID2/XPG mallinfo structure */
 
-struct mallinfo {
+struct mallinfo
+{
   int arena;    /* non-mmapped space allocated from system */
   int ordblks;  /* number of free chunks */
   int smblks;   /* number of fastbin blocks */
@@ -105,7 +114,7 @@
 };
 
 /* Returns a copy of the updated current mallinfo. */
-extern struct mallinfo mallinfo __MALLOC_P ((void));
+extern struct mallinfo mallinfo (void) __THROW;
 
 /* SVID2/XPG mallopt options */
 #ifndef M_MXFAST
@@ -132,47 +141,53 @@
 #define M_ARENA_MAX	    -8
 
 /* General SVID/XPG interface to tunable parameters. */
-extern int mallopt __MALLOC_P ((int __param, int __val));
+extern int mallopt (int __param, int __val) __THROW;
 
 /* Release all but __pad bytes of freed top-most memory back to the
    system. Return 1 if successful, else 0. */
-extern int malloc_trim __MALLOC_P ((size_t __pad));
+extern int malloc_trim (size_t __pad) __THROW;
 
 /* Report the number of usable allocated bytes associated with allocated
    chunk __ptr. */
-extern size_t malloc_usable_size __MALLOC_P ((void *__ptr));
+extern size_t malloc_usable_size (void *__ptr) __THROW;
 
 /* Prints brief summary statistics on stderr. */
-extern void malloc_stats __MALLOC_P ((void));
+extern void malloc_stats (void) __THROW;
 
 /* Output information about state of allocator to stream FP.  */
-extern int malloc_info (int __options, FILE *__fp);
+extern int malloc_info (int __options, FILE *__fp) __THROW;
 
 /* Record the state of all malloc variables in an opaque data structure. */
-extern void *malloc_get_state __MALLOC_P ((void));
+extern void *malloc_get_state (void) __THROW;
 
 /* Restore the state of all malloc variables from data obtained with
    malloc_get_state(). */
-extern int malloc_set_state __MALLOC_P ((void *__ptr));
+extern int malloc_set_state (void *__ptr) __THROW;
 
 /* Called once when malloc is initialized; redefining this variable in
    the application provides the preferred way to set up the hook
    pointers. */
-extern void (*__malloc_initialize_hook) __MALLOC_PMT ((void));
+extern void (*__MALLOC_HOOK_VOLATILE __malloc_initialize_hook) (void)
+     __MALLOC_DEPRECATED;
 /* Hooks for debugging and user-defined versions. */
-extern void (*__free_hook) __MALLOC_PMT ((void *__ptr,
-					__const __malloc_ptr_t));
-extern void *(*__malloc_hook) __MALLOC_PMT ((size_t __size,
-					     __const __malloc_ptr_t));
-extern void *(*__realloc_hook) __MALLOC_PMT ((void *__ptr, size_t __size,
-					      __const __malloc_ptr_t));
-extern void *(*__memalign_hook) __MALLOC_PMT ((size_t __alignment,
-					       size_t __size,
-					       __const __malloc_ptr_t));
-extern void (*__after_morecore_hook) __MALLOC_PMT ((void));
+extern void (*__MALLOC_HOOK_VOLATILE __free_hook) (void *__ptr,
+						   __const __malloc_ptr_t)
+     __MALLOC_DEPRECATED;
+extern void *(*__MALLOC_HOOK_VOLATILE __malloc_hook) (size_t __size,
+						      __const __malloc_ptr_t)
+     __MALLOC_DEPRECATED;
+extern void *(*__MALLOC_HOOK_VOLATILE __realloc_hook) (void *__ptr,
+						       size_t __size,
+						       __const __malloc_ptr_t)
+     __MALLOC_DEPRECATED;
+extern void *(*__MALLOC_HOOK_VOLATILE __memalign_hook) (size_t __alignment,
+							size_t __size,
+							__const __malloc_ptr_t)
+     __MALLOC_DEPRECATED;
+extern void (*__MALLOC_HOOK_VOLATILE __after_morecore_hook) (void);
 
 /* Activate a standard set of debugging hooks. */
-extern void __malloc_check_init __MALLOC_P ((void));
+extern void __malloc_check_init (void) __THROW __MALLOC_DEPRECATED;
 
 
 __END_DECLS

Modified: fsf/trunk/libc/resolv/res_init.c
==============================================================================
--- fsf/trunk/libc/resolv/res_init.c (original)
+++ fsf/trunk/libc/resolv/res_init.c Mon May 30 00:03:26 2011
@@ -521,37 +521,42 @@
 			}
 			printf(";;\tdebug\n");
 #endif
-		} else if (!strncmp(cp, "inet6", sizeof("inet6") - 1)) {
-			statp->options |= RES_USE_INET6;
-		} else if (!strncmp(cp, "ip6-bytestring",
-				    sizeof("ip6-bytestring") - 1)) {
-			statp->options |= RES_USEBSTRING;
-		} else if (!strncmp(cp, "no-ip6-dotint",
-				    sizeof("no-ip6-dotint") - 1)) {
-			statp->options |= RES_NOIP6DOTINT;
-		} else if (!strncmp(cp, "ip6-dotint",
-				    sizeof("ip6-dotint") - 1)) {
-			statp->options &= ~RES_NOIP6DOTINT;
-		} else if (!strncmp(cp, "rotate", sizeof("rotate") - 1)) {
-			statp->options |= RES_ROTATE;
-		} else if (!strncmp(cp, "no-check-names",
-				    sizeof("no-check-names") - 1)) {
-			statp->options |= RES_NOCHECKNAME;
-		} else if (!strncmp(cp, "edns0", sizeof("edns0") - 1)) {
-			statp->options |= RES_USE_EDNS0;
-		} else if (!strncmp(cp, "single-request-reopen",
-				    sizeof("single-request-reopen") - 1)) {
-			statp->options |= RES_SNGLKUPREOP;
-		} else if (!strncmp(cp, "single-request",
-				    sizeof("single-request") - 1)) {
-			statp->options |= RES_SNGLKUP;
-		} else if (!strncmp(cp, "no_tld_query",
-				    sizeof("no_tld_query") - 1) ||
-			   !strncmp(cp, "no-tld-query",
-				    sizeof("no-tld-query") - 1)) {
-			statp->options |= RES_NOTLDQUERY;
 		} else {
-			/* XXX - print a warning here? */
+		  static const struct
+		  {
+		    char str[22];
+		    uint8_t len;
+		    uint8_t clear;
+		    unsigned long int flag;
+		  } options[] = {
+#define STRnLEN(str) str, sizeof (str) - 1
+		    { STRnLEN ("inet6"), 0, RES_USE_INET6 },
+		    { STRnLEN ("ip6-bytestring"), 0, RES_USEBSTRING },
+		    { STRnLEN ("no-ip6-dotint"), 0, RES_NOIP6DOTINT },
+		    { STRnLEN ("ip6-dotint"), 1, ~RES_NOIP6DOTINT },
+		    { STRnLEN ("rotate"), 0, RES_ROTATE },
+		    { STRnLEN ("no-check-names"), 0, RES_NOCHECKNAME },
+		    { STRnLEN ("edns0"), 0, RES_USE_EDNS0 },
+		    { STRnLEN ("single-request-reopen"), 0, RES_SNGLKUPREOP },
+		    { STRnLEN ("single-request"), 0, RES_SNGLKUP },
+		    { STRnLEN ("no_tld_query"), 0, RES_NOTLDQUERY },
+		    { STRnLEN ("no-tld-query"), 0, RES_NOTLDQUERY },
+		    { STRnLEN ("use-vc"), 0, RES_USEVC }
+		  };
+#define noptions (sizeof (options) / sizeof (options[0]))
+		  int i;
+		  for (i = 0; i < noptions; ++i)
+		    if (strncmp (cp, options[i].str, options[i].len) == 0)
+		      {
+			if (options[i].clear)
+			  statp->options &= options[i].flag;
+			else
+			  statp->options |= options[i].flag;
+			break;
+		      }
+		  if (i == noptions) {
+		    /* XXX - print a warning here? */
+		  }
 		}
 		/* skip to next run of spaces */
 		while (*cp && *cp != ' ' && *cp != '\t')

Modified: fsf/trunk/libc/shadow/sgetspent_r.c
==============================================================================
--- fsf/trunk/libc/shadow/sgetspent_r.c (original)
+++ fsf/trunk/libc/shadow/sgetspent_r.c Mon May 30 00:03:26 2011
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996, 1997, 1998, 2005, 2009 Free Software Foundation, Inc.
+/* Copyright (C) 1996-1998, 2005, 2009, 2011 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
@@ -52,11 +52,11 @@
  else
    {
      STRING_FIELD (result->sp_pwdp, ISCOLON, 0);
-     INT_FIELD_MAYBE_NULL (result->sp_lstchg, ISCOLON, 0, 10, (long int),
+     INT_FIELD_MAYBE_NULL (result->sp_lstchg, ISCOLON, 0, 10, (long int) (int),
 			   (long int) -1);
-     INT_FIELD_MAYBE_NULL (result->sp_min, ISCOLON, 0, 10, (long int),
+     INT_FIELD_MAYBE_NULL (result->sp_min, ISCOLON, 0, 10, (long int) (int),
 			   (long int) -1);
-     INT_FIELD_MAYBE_NULL (result->sp_max, ISCOLON, 0, 10, (long int),
+     INT_FIELD_MAYBE_NULL (result->sp_max, ISCOLON, 0, 10, (long int) (int),
 			   (long int) -1);
      while (isspace (*line))
        ++line;
@@ -70,12 +70,12 @@
        }
      else
        {
-	 INT_FIELD_MAYBE_NULL (result->sp_warn, ISCOLON, 0, 10, (long int),
-			       (long int) -1);
-	 INT_FIELD_MAYBE_NULL (result->sp_inact, ISCOLON, 0, 10, (long int),
-			       (long int) -1);
-	 INT_FIELD_MAYBE_NULL (result->sp_expire, ISCOLON, 0, 10, (long int),
-			       (long int) -1);
+	 INT_FIELD_MAYBE_NULL (result->sp_warn, ISCOLON, 0, 10,
+			       (long int) (int), (long int) -1);
+	 INT_FIELD_MAYBE_NULL (result->sp_inact, ISCOLON, 0, 10,
+			       (long int) (int), (long int) -1);
+	 INT_FIELD_MAYBE_NULL (result->sp_expire, ISCOLON, 0, 10,
+			       (long int) (int), (long int) -1);
 	 if (*line != '\0')
 	   INT_FIELD_MAYBE_NULL (result->sp_flag, FALSEP, 0, 10,
 				 (unsigned long int), ~0ul)

Modified: fsf/trunk/libc/sysdeps/posix/getaddrinfo.c
==============================================================================
--- fsf/trunk/libc/sysdeps/posix/getaddrinfo.c (original)
+++ fsf/trunk/libc/sysdeps/posix/getaddrinfo.c Mon May 30 00:03:26 2011
@@ -207,7 +207,7 @@
       if (herrno == NETDB_INTERNAL)					      \
 	{								      \
 	  __set_h_errno (herrno);					      \
-	  _res.options = old_res_options;				      \
+	  _res.options |= old_res_options & RES_USE_INET6;		      \
 	  return -EAI_SYSTEM;						      \
 	}								      \
       if (herrno == TRY_AGAIN)						      \
@@ -1015,7 +1015,7 @@
 		nip = nip->next;
 	    }
 
-	  _res.options = old_res_options;
+	  _res.options |= old_res_options & RES_USE_INET6;
 
 	  if (no_data != 0 && no_inet6_data != 0)
 	    {

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/bits/siginfo.h
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/bits/siginfo.h (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/bits/siginfo.h Mon May 30 00:03:26 2011
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  Linux version.
-   Copyright (C) 1997-2002, 2003 Free Software Foundation, Inc.
+   Copyright (C) 1997-2002, 2003, 2011 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
@@ -142,7 +142,7 @@
 # define SI_TIMER	SI_TIMER
   SI_QUEUE,			/* Sent by sigqueue.  */
 # define SI_QUEUE	SI_QUEUE
-  SI_USER,			/* Sent by kill, sigsend, raise.  */
+  SI_USER,			/* Sent by kill, sigsend.  */
 # define SI_USER	SI_USER
   SI_KERNEL = 0x80		/* Send by kernel.  */
 #define SI_KERNEL	SI_KERNEL

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/ia64/bits/siginfo.h Mon May 30 00:03:26 2011
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  Linux/ia64 version.
-   Copyright (C) 2000-2004, 2009 Free Software Foundation, Inc.
+   Copyright (C) 2000-2004, 2009, 2011 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
    Contributed by David Mosberger-Tang <davidm@xxxxxxxxxx>.
 
@@ -146,7 +146,7 @@
 # define SI_TIMER	SI_TIMER
   SI_QUEUE,			/* Sent by sigqueue.  */
 # define SI_QUEUE	SI_QUEUE
-  SI_USER,			/* Sent by kill, sigsend, raise.  */
+  SI_USER,			/* Sent by kill, sigsend.  */
 # define SI_USER	SI_USER
   SI_KERNEL = 0x80		/* Send by kernel.  */
 #define SI_KERNEL	SI_KERNEL

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/s390/bits/siginfo.h
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/s390/bits/siginfo.h (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/s390/bits/siginfo.h Mon May 30 00:03:26 2011
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  S/390 version.
-   Copyright (C) 2001, 2002, 2003, 2009 Free Software Foundation, Inc.
+   Copyright (C) 2001, 2002, 2003, 2009, 2011 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
@@ -144,7 +144,7 @@
 # define SI_TIMER	SI_TIMER
   SI_QUEUE,			/* Sent by sigqueue.  */
 # define SI_QUEUE	SI_QUEUE
-  SI_USER,			/* Sent by kill, sigsend, raise.  */
+  SI_USER,			/* Sent by kill, sigsend.  */
 # define SI_USER	SI_USER
   SI_KERNEL = 0x80		/* Send by kernel.  */
 #define SI_KERNEL	SI_KERNEL

Modified: fsf/trunk/libc/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h
==============================================================================
--- fsf/trunk/libc/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h (original)
+++ fsf/trunk/libc/sysdeps/unix/sysv/linux/sparc/bits/siginfo.h Mon May 30 00:03:26 2011
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  Linux/SPARC version.
-   Copyright (C) 1997-2002, 2003 Free Software Foundation, Inc.
+   Copyright (C) 1997-2002, 2003, 2011 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
@@ -144,7 +144,7 @@
 # define SI_TIMER	SI_TIMER
   SI_QUEUE,			/* Sent by sigqueue.  */
 # define SI_QUEUE	SI_QUEUE
-  SI_USER,			/* Sent by kill, sigsend, raise.  */
+  SI_USER,			/* Sent by kill, sigsend.  */
 # define SI_USER	SI_USER
   SI_KERNEL = 0x80		/* Send by kernel.  */
 #define SI_KERNEL	SI_KERNEL