aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libctf/ChangeLog4
-rw-r--r--libctf/ctf-link.c1
2 files changed, 5 insertions, 0 deletions
diff --git a/libctf/ChangeLog b/libctf/ChangeLog
index c3451ee..848bc48 100644
--- a/libctf/ChangeLog
+++ b/libctf/ChangeLog
@@ -1,5 +1,9 @@
2020-07-22 Nick Alcock <nick.alcock@oracle.com>
+ * ctf-link.c (ctf_link_write): Close the fd.
+
+2020-07-22 Nick Alcock <nick.alcock@oracle.com>
+
* Makefile.am: Set -DNOBFD=1 in libctf-nobfd, and =0 elsewhere.
* Makefile.in: Regenerated.
* ctf-impl.h (ctf_link_input_name): New.
diff --git a/libctf/ctf-link.c b/libctf/ctf-link.c
index 705701d..fa15c9b 100644
--- a/libctf/ctf-link.c
+++ b/libctf/ctf-link.c
@@ -1071,6 +1071,7 @@ ctf_link_write (ctf_file_t *fp, size_t *size, size_t threshold)
free (arg.dynames[i]);
free (arg.dynames);
}
+ fclose (f);
return buf;
err_no: