PR binutils/14481
authorHans-Peter Nilsson <hp@axis.com>
Wed, 7 Nov 2012 05:51:37 +0000 (05:51 +0000)
committerHans-Peter Nilsson <hp@axis.com>
Wed, 7 Nov 2012 05:51:37 +0000 (05:51 +0000)
* aout-target.h (MY_close_and_cleanup): Make local function
instead of alias of MY_bfd_free_cached_info.  Also call
_bfd_generic_close_and_cleanup.

bfd/ChangeLog
bfd/aout-target.h

index 530ef7d61bc72dd33308fba6d374d35380802c3f..a2fb2967df74332a9349b1ccd57e94655498473a 100644 (file)
@@ -1,3 +1,10 @@
+2012-11-07  Hans-Peter Nilsson  <hp@axis.com>
+
+       PR binutils/14481
+       * aout-target.h (MY_close_and_cleanup): Make local function
+       instead of alias of MY_bfd_free_cached_info.  Also call
+       _bfd_generic_close_and_cleanup.
+
 2012-11-06  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR binutils/14813
index f6e8bd2e2dc00017896c1636332659095e44da78..1ffef871627d4d99b963d210288eea0701333f42 100644 (file)
@@ -577,7 +577,18 @@ MY_bfd_final_link (bfd *abfd, struct bfd_link_info *info)
 #endif
 
 #ifndef MY_close_and_cleanup
-#define MY_close_and_cleanup MY_bfd_free_cached_info
+
+/* Handle closing of a BFD including the resource-releasing parts.  */
+
+static bfd_boolean
+MY_close_and_cleanup (bfd *abfd)
+{
+  if (!MY_bfd_free_cached_info (abfd))
+    return FALSE;
+
+  return _bfd_generic_close_and_cleanup (abfd);
+}
+
 #endif
 
 #ifndef MY_get_dynamic_symtab_upper_bound