This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug dynamic-link/19329] dl-tls.c assert failure at concurrent pthread_create and dlopen
- From: "P at draigBrady dot com" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sourceware dot org
- Date: Fri, 29 Sep 2017 23:54:54 +0000
- Subject: [Bug dynamic-link/19329] dl-tls.c assert failure at concurrent pthread_create and dlopen
- Auto-submitted: auto-generated
- References: <bug-19329-131@http.sourceware.org/bugzilla/>
https://sourceware.org/bugzilla/show_bug.cgi?id=19329
--- Comment #9 from Pádraig Brady <P at draigBrady dot com> ---
We found an off by one issue with this (with ASAN + certain number of shared
libs). When the last vector in the _dl_allocate_tls_init list of vectors was of
size one it would have been skipped. The fix is:
diff --git a/elf/dl-tls.c b/elf/dl-tls.c
index 073321c..2c9ad2a 100644
--- a/elf/dl-tls.c
+++ b/elf/dl-tls.c
@@ -571,7 +571,7 @@ _dl_allocate_tls_init (void *result)
}
total += cnt;
- if (total >= dtv_slots)
+ if (total > dtv_slots)
break;
/* Synchronize with dl_add_to_slotinfo. */
--
You are receiving this mail because:
You are on the CC list for the bug.