[binutils-gdb] Call _close_and_cleanup in bfd_close_all_done

H.J.Lu hjl@sourceware.org
Wed Aug 30 13:23:00 GMT 2017


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=7c0ed39626e3193adb70aeb98d3633787579d6ec

commit 7c0ed39626e3193adb70aeb98d3633787579d6ec
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Wed Aug 30 06:17:28 2017 -0700

    Call _close_and_cleanup in bfd_close_all_done
    
    	PR binutils/22032
    	* opncls.c (bfd_close_all_done): Call _close_and_cleanup.

Diff:
---
 bfd/ChangeLog | 5 +++++
 bfd/opncls.c  | 3 +++
 2 files changed, 8 insertions(+)

diff --git a/bfd/ChangeLog b/bfd/ChangeLog
index bf509b6..4882260 100644
--- a/bfd/ChangeLog
+++ b/bfd/ChangeLog
@@ -1,5 +1,10 @@
 2017-08-30  H.J. Lu  <hongjiu.lu@intel.com>
 
+	PR binutils/22032
+	* opncls.c (bfd_close_all_done): Call _close_and_cleanup.
+
+2017-08-30  H.J. Lu  <hongjiu.lu@intel.com>
+
 	* elf64-x86-64.c (elf_x86_64_next_tls_desc_index): Removed.
 	(elf_x86_64_srelplt2): Likewise.
 
diff --git a/bfd/opncls.c b/bfd/opncls.c
index 913341c..b99ae72 100644
--- a/bfd/opncls.c
+++ b/bfd/opncls.c
@@ -776,6 +776,9 @@ bfd_close_all_done (bfd *abfd)
 
   ret = bfd_cache_close (abfd);
 
+  if (! BFD_SEND (abfd, _close_and_cleanup, (abfd)))
+    return FALSE;
+
   if (ret)
     _maybe_make_executable (abfd);



More information about the Binutils-cvs mailing list