bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug binutils/30060] ASAN error: in bfd_cache_close /buildworker/marxinb


From: amodra at gmail dot com
Subject: [Bug binutils/30060] ASAN error: in bfd_cache_close /buildworker/marxinbox-cross-binutils-sanitizers/build/bfd/cache.c:532
Date: Tue, 31 Jan 2023 00:14:01 +0000

https://sourceware.org/bugzilla/show_bug.cgi?id=30060

Alan Modra <amodra at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|amodra at gmail dot com            |
           Assignee|unassigned at sourceware dot org   |amodra at gmail dot com
             Status|NEW                         |ASSIGNED

--- Comment #1 from Alan Modra <amodra at gmail dot com> ---
Things go wrong here at ar.c:1302
  tmpfd = dup (tmpfd);
  if (!bfd_close (obfd))
    bfd_fatal (old_name);

The bfd_close returns an error, and when bfd_fatal calls exit the atexit
handlers include bucomm.c:remove_output.  remove_output calls bfd_cache_close,
which accesses the output bfd.  I reckon that remove_output should not be
calling bfd_cache_close, but it might also be the case that code that does this
sort of thing is common enough that we can't reclaim bfd memory in bfd_close or
bfd_close_all_done after an error.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]