packages: glibc/glibc-git.patch - missing patch

arekm arekm at pld-linux.org
Fri Jun 3 21:18:05 CEST 2011


Author: arekm                        Date: Fri Jun  3 19:18:05 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- missing patch

---- Files affected:
packages/glibc:
   glibc-git.patch (1.3 -> 1.4) 

---- Diffs:

================================================================
Index: packages/glibc/glibc-git.patch
diff -u /dev/null packages/glibc/glibc-git.patch:1.4
--- /dev/null	Fri Jun  3 21:18:05 2011
+++ packages/glibc/glibc-git.patch	Fri Jun  3 21:18:00 2011
@@ -0,0 +1,99 @@
+commit c8fc0c91695b1c7003c7170861274161f9224817
+Author: Ulrich Drepper <drepper at gmail.com>
+Date:   Tue May 31 08:45:44 2011 -0400
+
+    Don't free non-malloced memory and fix memory leak
+
+diff --git a/ChangeLog b/ChangeLog
+index 3a6abda..eee3d1b 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,8 @@
++2011-05-31  Andreas Schwab  <schwab at redhat.com>
++
++	* nscd/nscd_getserv_r.c (nscd_getserv_r): Don't free non-malloced
++	memory.  Use alloca_account.  Fix memory leak when retrying.
++
+ 2011-05-31  Ulrich Drepper  <drepper at gmail.com>
+ 
+ 	* version.h (RELEASE): Bump for 2.14 release.
+diff --git a/nscd/nscd_getserv_r.c b/nscd/nscd_getserv_r.c
+index de96a57..f9ef056 100644
+--- a/nscd/nscd_getserv_r.c
++++ b/nscd/nscd_getserv_r.c
+@@ -124,6 +124,7 @@ nscd_getserv_r (const char *crit, size_t critlen, const char *proto,
+ 	  s_name = (char *) (&found->data[0].servdata + 1);
+ 	  serv_resp = found->data[0].servdata;
+ 	  s_proto = s_name + serv_resp.s_name_len;
++	  alloca_aliases_len = 1;
+ 	  aliases_len = (uint32_t *) (s_proto + serv_resp.s_proto_len);
+ 	  aliases_list = ((char *) aliases_len
+ 			  + serv_resp.s_aliases_cnt * sizeof (uint32_t));
+@@ -154,7 +155,9 @@ nscd_getserv_r (const char *crit, size_t critlen, const char *proto,
+ 				     + (serv_resp.s_aliases_cnt
+ 					* sizeof (uint32_t)));
+ 	      if (alloca_aliases_len)
+-		tmp = __alloca (serv_resp.s_aliases_cnt * sizeof (uint32_t));
++		tmp = alloca_account (serv_resp.s_aliases_cnt
++				      * sizeof (uint32_t),
++				      alloca_used);
+ 	      else
+ 		{
+ 		  tmp = malloc (serv_resp.s_aliases_cnt * sizeof (uint32_t));
+@@ -249,8 +252,9 @@ nscd_getserv_r (const char *crit, size_t critlen, const char *proto,
+ 				     + (serv_resp.s_aliases_cnt
+ 					* sizeof (uint32_t)));
+ 	      if (alloca_aliases_len)
+-		aliases_len = alloca (serv_resp.s_aliases_cnt
+-				      * sizeof (uint32_t));
++		aliases_len = alloca_account (serv_resp.s_aliases_cnt
++					      * sizeof (uint32_t),
++					      alloca_used);
+ 	      else
+ 		{
+ 		  aliases_len = malloc (serv_resp.s_aliases_cnt
+@@ -368,7 +372,11 @@ nscd_getserv_r (const char *crit, size_t critlen, const char *proto,
+ 	}
+ 
+       if (retval != -1)
+-	goto retry;
++	{
++	  if (!alloca_aliases_len)
++	    free (aliases_len);
++	  goto retry;
++	}
+     }
+ 
+   if (!alloca_aliases_len)
+commit 8c29731192565b9c917d6b97db78dcd302283df8
+Author: Ulrich Drepper <drepper at gmail.com>
+Date:   Tue May 31 14:23:01 2011 -0400
+
+    Fix typo in  stack guard setup code for old kernels
+
+diff --git a/ChangeLog b/ChangeLog
+index eee3d1b..2aca74a 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,8 @@
++2011-05-31  Ulrich Drepper  <drepper at gmail.com>
++
++	* sysdeps/unix/sysv/linux/dl-osinfo.h (_dl_setup_stack_chk_guard): Fix
++	typo.
++
+ 2011-05-31  Andreas Schwab  <schwab at redhat.com>
+ 
+ 	* nscd/nscd_getserv_r.c (nscd_getserv_r): Don't free non-malloced
+diff --git a/sysdeps/unix/sysv/linux/dl-osinfo.h b/sysdeps/unix/sysv/linux/dl-osinfo.h
+index eb7fedc..28fce4f 100644
+--- a/sysdeps/unix/sysv/linux/dl-osinfo.h
++++ b/sysdeps/unix/sysv/linux/dl-osinfo.h
+@@ -81,7 +81,7 @@ _dl_setup_stack_chk_guard (void *dl_random)
+ 	{
+ 	  ssize_t reslen = read_not_cancel (fd, ret.bytes + 1, filllen);
+ 	  close_not_cancel_no_status (fd);
+-	  if (reslen == (ssize_) filllen)
++	  if (reslen == (ssize_t) filllen)
+ 	    return ret.num;
+ 	}
+ # endif
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/glibc/glibc-git.patch?r1=1.3&r2=1.4&f=u



More information about the pld-cvs-commit mailing list