diff options
author | Mark Wielaard <mark@klomp.org> | 2023-02-22 23:34:00 +0100 |
---|---|---|
committer | Mark Wielaard <mark@klomp.org> | 2023-02-28 12:35:15 +0100 |
commit | e24d8a4a3ea106608bb3e8d33c4639cf71d0f08d (patch) | |
tree | 47de840bd6ec8ec60bb2d828f2756d83d6354d04 /libdw/ChangeLog | |
parent | 4961f9ae2f11795022166698aa15a15f48ec8c5b (diff) | |
download | elfutils-e24d8a4a3ea106608bb3e8d33c4639cf71d0f08d.tar.gz |
libdw: Fix dwarf_getscopes memory leak on error
When there is an error in dwarf_getscopes after the initial scopes
have been allocated, e.g. when looking for the inlined scopes, then
the scopes would leak. Fix this by explicitly free the scopes on error.
https://sourceware.org/bugzilla/show_bug.cgi?id=29434
Signed-off-by: Mark Wielaard <mark@klomp.org>
Diffstat (limited to 'libdw/ChangeLog')
-rw-r--r-- | libdw/ChangeLog | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libdw/ChangeLog b/libdw/ChangeLog index 5e60f786..406310ef 100644 --- a/libdw/ChangeLog +++ b/libdw/ChangeLog @@ -1,3 +1,8 @@ +2023-02-22 Mark Wielaard <mark@klomp.org> + + * dwarf_getscopes.c (origin_match): Don't free a->scopes. + (dwarf_getscopes): Free a->scopes on error. + 2023-02-20 Mark Wielaard <mark@klomp.org> * dwarf_begin_elf.c (check_section): Use elf_rawdata. |