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

r6657 - in glibc-package/branches/glibc-branch-jessie/debian: . patches patches/any



Author: aurel32
Date: 2015-10-19 10:12:15 +0000 (Mon, 19 Oct 2015)
New Revision: 6657

Added:
   glibc-package/branches/glibc-branch-jessie/debian/patches/any/cvs-mangle-tls_dtor_list.diff
Modified:
   glibc-package/branches/glibc-branch-jessie/debian/changelog
   glibc-package/branches/glibc-branch-jessie/debian/patches/series
Log:
patches/any/cvs-mangle-tls_dtor_list.diff: new patch from upstream to
mangle function pointers in tls_dtor_list.  Closes: #802256.

Modified: glibc-package/branches/glibc-branch-jessie/debian/changelog
===================================================================
--- glibc-package/branches/glibc-branch-jessie/debian/changelog	2015-10-19 10:10:17 UTC (rev 6656)
+++ glibc-package/branches/glibc-branch-jessie/debian/changelog	2015-10-19 10:12:15 UTC (rev 6657)
@@ -8,6 +8,8 @@
       (CVE-2015-5277).  Closes: #799966.
   * patches/any/cvs-ld_pointer_guard.diff: new patch from upstream to
     unconditionally disable LD_POINTER_GUARD.  Closes: #798316, #801691.
+  * patches/any/cvs-mangle-tls_dtor_list.diff: new patch from upstream to
+    mangle function pointers in tls_dtor_list.  Closes: #802256.
 
   [ Henrique de Moraes Holschuh ]
   * Replace patches/amd64/local-blacklist-on-TSX-Haswell.diff by 

Added: glibc-package/branches/glibc-branch-jessie/debian/patches/any/cvs-mangle-tls_dtor_list.diff
===================================================================
--- glibc-package/branches/glibc-branch-jessie/debian/patches/any/cvs-mangle-tls_dtor_list.diff	                        (rev 0)
+++ glibc-package/branches/glibc-branch-jessie/debian/patches/any/cvs-mangle-tls_dtor_list.diff	2015-10-19 10:12:15 UTC (rev 6657)
@@ -0,0 +1,35 @@
+2015-10-06  Florian Weimer  <fweimer@redhat.com>
+
+	[BZ #19018]
+	* stdlib/cxa_thread_atexit_impl.c (__cxa_thread_atexit_impl):
+	Mangle function pointer before storing it.
+	(__call_tls_dtors): Demangle function pointer before calling it.
+
+--- a/stdlib/cxa_thread_atexit_impl.c
++++ b/stdlib/cxa_thread_atexit_impl.c
+@@ -42,6 +42,10 @@
+ int
+ __cxa_thread_atexit_impl (dtor_func func, void *obj, void *dso_symbol)
+ {
++#ifdef PTR_MANGLE
++  PTR_MANGLE (func);
++#endif
++
+   /* Prepend.  */
+   struct dtor_list *new = calloc (1, sizeof (struct dtor_list));
+   new->func = func;
+@@ -83,9 +87,13 @@
+   while (tls_dtor_list)
+     {
+       struct dtor_list *cur = tls_dtor_list;
++      dtor_func func = cur->func;
++#ifdef PTR_DEMANGLE
++      PTR_DEMANGLE (func);
++#endif
+       tls_dtor_list = tls_dtor_list->next;
+ 
+-      cur->func (cur->obj);
++      func (cur->obj);
+ 
+       __rtld_lock_lock_recursive (GL(dl_load_lock));
+ 

Modified: glibc-package/branches/glibc-branch-jessie/debian/patches/series
===================================================================
--- glibc-package/branches/glibc-branch-jessie/debian/patches/series	2015-10-19 10:10:17 UTC (rev 6656)
+++ glibc-package/branches/glibc-branch-jessie/debian/patches/series	2015-10-19 10:12:15 UTC (rev 6657)
@@ -273,3 +273,4 @@
 any/cvs-wscanf.diff
 any/cvs-ldconfig-aux-cache.diff
 any/cvs-ld_pointer_guard.diff
+any/cvs-mangle-tls_dtor_list.diff


Reply to: