summaryrefslogtreecommitdiff
path: root/libdwfl/dwfl_report_elf.c
diff options
context:
space:
mode:
authorMark Wielaard <mjw@redhat.com>2009-06-18 13:31:56 +0200
committerRoland McGrath <roland@redhat.com>2009-06-18 13:59:41 -0700
commit2256e360a13df88ae3d3e8697f1753dc19be70c0 (patch)
treeeed7725b41ddcc07fd25150ff305d603b867031c /libdwfl/dwfl_report_elf.c
parent05c4e04640d173a4d1ce6e2f25a24060c21a67ab (diff)
downloadelfutils-2256e360a13df88ae3d3e8697f1753dc19be70c0.tar.gz
__libdwfl_report_elf: Return NULL on overlap, don't (double) close elf.
Diffstat (limited to 'libdwfl/dwfl_report_elf.c')
-rw-r--r--libdwfl/dwfl_report_elf.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libdwfl/dwfl_report_elf.c b/libdwfl/dwfl_report_elf.c
index a58d3029..52b0c57d 100644
--- a/libdwfl/dwfl_report_elf.c
+++ b/libdwfl/dwfl_report_elf.c
@@ -235,11 +235,10 @@ __libdwfl_report_elf (Dwfl *dwfl, const char *name, const char *file_name,
else if ((fd >= 0 && m->main.fd != fd)
|| strcmp (m->main.name, file_name))
{
- elf_end (elf);
overlap:
m->gc = true;
__libdwfl_seterrno (DWFL_E_OVERLAP);
- m = NULL;
+ return NULL;
}
/* Preinstall the open ELF handle for the module. */