diff options
author | Robert Mustacchi <rm@fingolfin.org> | 2021-07-31 16:38:27 -0700 |
---|---|---|
committer | Robert Mustacchi <rm@fingolfin.org> | 2021-08-17 09:03:38 -0700 |
commit | 9148a91fab5cca2666b01bab18514159f4480f9e (patch) | |
tree | 672822546b82569c2e78d0030c89a299797876de | |
parent | 50d4d24e9f62b588d2123e06f654ecb230e4857c (diff) | |
download | illumos-joyent-9148a91fab5cca2666b01bab18514159f4480f9e.tar.gz |
13989 libproc can leak core CTF data
Reviewed by: Andy Fiddaman <andy@omnios.org>
Reviewed by: Toomas Soome <tsoome@me.com>
Approved by: Dan McDonald <danmcd@joyent.com>
-rw-r--r-- | usr/src/lib/libproc/common/Psymtab.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/usr/src/lib/libproc/common/Psymtab.c b/usr/src/lib/libproc/common/Psymtab.c index e6fc676ee0..b92e5a7d56 100644 --- a/usr/src/lib/libproc/common/Psymtab.c +++ b/usr/src/lib/libproc/common/Psymtab.c @@ -298,10 +298,8 @@ file_info_free(struct ps_prochandle *P, file_info_t *fptr) (void) elf_end(fptr->file_dbgelf); if (fptr->file_dbgfile >= 0) (void) close(fptr->file_dbgfile); - if (fptr->file_ctfp) { - ctf_close(fptr->file_ctfp); - free(fptr->file_ctf_buf); - } + ctf_close(fptr->file_ctfp); + free(fptr->file_ctf_buf); if (fptr->file_saddrs) free(fptr->file_saddrs); free(fptr); |