aboutsummaryrefslogtreecommitdiff
path: root/lib/libproc/proc_create.c
diff options
context:
space:
mode:
authorMark Johnston <markj@FreeBSD.org>2016-12-06 04:21:35 +0000
committerMark Johnston <markj@FreeBSD.org>2016-12-06 04:21:35 +0000
commitc156354ff82167219f10fd80c55f6452acb60328 (patch)
treeec2cd0c2bf934ed37a4e369d3c9ae57a9dc95cd7 /lib/libproc/proc_create.c
parentd42df2a44793413692a006e46faad87ec7b9e34f (diff)
Notes
Diffstat (limited to 'lib/libproc/proc_create.c')
-rw-r--r--lib/libproc/proc_create.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/libproc/proc_create.c b/lib/libproc/proc_create.c
index a4ac3cc8a15c..36f27099c739 100644
--- a/lib/libproc/proc_create.c
+++ b/lib/libproc/proc_create.c
@@ -239,6 +239,10 @@ proc_free(struct proc_handle *phdl)
if (file->elf != NULL) {
(void)elf_end(file->elf);
(void)close(file->fd);
+ if (file->symtab.nsyms > 0)
+ free(file->symtab.index);
+ if (file->dynsymtab.nsyms > 0)
+ free(file->dynsymtab.index);
}
free(file);
}