]> granicus.if.org Git - gc/commit
Fix leak_test crash in print_callers if free() is redirected
authorIvan Maidanski <ivmai@mail.ru>
Mon, 7 Aug 2017 08:37:30 +0000 (11:37 +0300)
committerIvan Maidanski <ivmai@mail.ru>
Mon, 7 Aug 2017 08:37:30 +0000 (11:37 +0300)
commit348bc2ba8d5556f4e655675b94e1b29e80b40fdc
treec5ab178daf2447e3678f1d5debf299c2d80a2472
parent13e834307b2605b5669be5e90b24df9a93469f58
Fix leak_test crash in print_callers if free() is redirected

* dbg_mlc.c [REDIRECT_MALLOC && (GC_LINUX_THREADS || GC_SOLARIS_THREADS
|| MSWIN32 || NEED_CALLINFO && GC_HAVE_BUILTIN_BACKTRACE)]
(GC_debug_free): If the object is not in the GC heap then just return
(instead of ABORT).
* malloc.c [REDIRECT_MALLOC && NEED_CALLINFO
&& GC_HAVE_BUILTIN_BACKTRACE] (GC_free): If hhdr is null (i.e. the
object is not in the GC heap) then return without the object
deallocation; add comment.
* os_dep.c [NEED_CALLINFO && GC_HAVE_BUILTIN_BACKTRACE
&& !GC_BACKTRACE_SYMBOLS_BROKEN] (GC_print_callers): Adjust comment
for free().
dbg_mlc.c
malloc.c
os_dep.c