]> gcc.gnu.org Git - gcc.git/commit
[libbacktrace] Fix memory leak in build_address_map
authorTom de Vries <tdevries@suse.de>
Fri, 28 Dec 2018 03:43:15 +0000 (03:43 +0000)
committerTom de Vries <vries@gcc.gnu.org>
Fri, 28 Dec 2018 03:43:15 +0000 (03:43 +0000)
commit53a52133a5fc74d63ce17b328774706bf1e79e02
treebb5714dffebc534c285ee313fee9c02d9645cbce
parentf14303090835f84474b6bf8c38bc0d07dbfc2069
[libbacktrace] Fix memory leak in build_address_map

While upon failure in build_address_map we call free_unit_addrs_vector, this
does not actually free the addrs vector, but merely the abbrevs of the units
pointed at by the elements of the addrs vector.

Fix this by adding code to build_address_map to make sure that the addrs vector
is freed upon failure.

Bootstrapped and reg-tested on x86_64.

2018-12-28  Tom de Vries  <tdevries@suse.de>

* dwarf.c (build_address_map): Free addrs vector upon failure.

From-SVN: r267442
libbacktrace/ChangeLog
libbacktrace/dwarf.c
This page took 0.054508 seconds and 5 git commands to generate.