[patch ld]: Close BFDs before linker-plugin's atexit routine is called

Kai Tietz ktietz70@googlemail.com
Sun Feb 13 10:40:00 GMT 2011


PING.

2011/2/9 Kai Tietz <ktietz70@googlemail.com>:
> Hello,
>
> This is patch addresses the unlink call when lto linker-plugin is
> used.  As windows
> native doesn't support to unlink still opened files, it fails to do so
> as file-descriptors
> of bfds aren't closed before atexit routine of plugin gets called.
>
> 2011-02-09  Kai Tietz
>
>        * ldmain.c (remove_output): Set output_bfd
>        of link_info to nil and close all cached bfds.
>        (main): Close output_bfd of link_info and set
>        it to nil. Additionally close all cached bfds.
>
> Tested on x86_64-pc-linux-gnu and x86_64-w64-mingw32. Ok for apply?
>
> Regards,
> Kai
>



-- 
|  (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination



More information about the Binutils mailing list