1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-29 11:41:21 +03:00

Always check dtv before freeing dtv[-1]

This commit is contained in:
H.J. Lu
2012-09-05 12:24:37 -07:00
parent f5fce0629a
commit 0948c3af9d
3 changed files with 9 additions and 2 deletions

View File

@ -477,9 +477,7 @@ _dl_deallocate_tls (void *tcb, bool dealloc_tcb)
free (dtv[1 + cnt].pointer.val);
/* The array starts with dtv[-1]. */
#ifdef SHARED
if (dtv != GL(dl_initial_dtv))
#endif
free (dtv - 1);
if (dealloc_tcb)