diff options
author | Maxim Kuvyrkov <maxim@kugelworks.com> | 2013-12-24 09:44:50 +1300 |
---|---|---|
committer | Maxim Kuvyrkov <maxim@kugelworks.com> | 2014-01-05 14:56:39 +1300 |
commit | 8b43a2274a593ce91e673db1cfac6e808134bc84 (patch) | |
tree | 563557cb2f148aadd2b928f9e7b900f8267d5de3 /debug | |
parent | ca0dd6386ed2b5c5c6ca392547628a1228432ae0 (diff) | |
download | glibc-8b43a2274a593ce91e673db1cfac6e808134bc84.tar.gz |
Fix race in free() of fastbin chunk: BZ #15073
Perform sanity check only if we have_lock. Due to lockless nature of fastbins
we need to be careful derefencing pointers to fastbin entries (chunksize(old)
in this case) in multithreaded environments.
The fix is to add have_lock to the if-condition checks. The rest of the patch
only makes code more readable.
* malloc/malloc.c (_int_free): Perform sanity check only if we
have_lock.
Conflicts:
ChangeLog
NEWS
Diffstat (limited to 'debug')
0 files changed, 0 insertions, 0 deletions