2
0
mirror of git://sourceware.org/git/glibc.git synced 2025-04-06 14:10:30 +08:00
DJ Delorie 4b246928bd malloc: tcache double free check
* malloc/malloc.c (tcache_entry): Add key field.
(tcache_put): Set it.
(tcache_get): Likewise.
(_int_free): Check for double free in tcache.
* malloc/tst-tcfree1.c: New.
* malloc/tst-tcfree2.c: New.
* malloc/Makefile: Run the new tests.
* manual/probes.texi: Document memory_tcache_double_free probe.

* dlfcn/dlerror.c (check_free): Prevent double frees.

(cherry picked from commit bcdaad21d4635931d1bd3b54a7894276925d081d)

malloc: tcache: Validate tc_idx before checking for double-frees [BZ ]

The previous check could read beyond the end of the tcache entry
array.  If the e->key == tcache cookie check happened to pass, this
would result in crashes.

(cherry picked from commit affec03b713c82c43a5b025dddc21bde3334f41e)
2018-12-12 13:22:42 +01:00
..
2005-09-28 00:14:50 +00:00
2005-09-28 00:14:50 +00:00
2013-06-05 20:44:03 +00:00
2018-12-12 13:22:42 +01:00
2014-11-27 16:00:08 +00:00
2007-07-12 18:17:11 +00:00
2015-01-21 01:51:10 -05:00
2015-01-21 01:51:10 -05:00
2013-09-04 15:25:42 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00
2004-10-18 23:17:46 +00:00