]> git.ipfire.org Git - thirdparty/glibc.git/commit
Fix deadlock in _int_free consistency check
authorWilco Dijkstra <wdijkstr@arm.com>
Thu, 19 Oct 2017 17:19:55 +0000 (18:19 +0100)
committerWilco Dijkstra <wdijkstr@arm.com>
Thu, 19 Oct 2017 17:19:55 +0000 (18:19 +0100)
commitd74e6f6c0de55fc588b1ac09c88eb0fb8b8600af
treee75ef871621bf3c08b6c18bf5f31a373a37fc9a4
parent4d916f0f12b230f49967797f98b2b613c734a047
Fix deadlock in _int_free consistency check

This patch fixes a deadlock in the fastbin consistency check.
If we fail the fast check due to concurrent modifications to
the next chunk or system_mem, we should not lock if we already
have the arena lock.  Simplify the check to make it obviously
correct.

* malloc/malloc.c (_int_free): Fix deadlock bug in consistency check.
ChangeLog
malloc/malloc.c