diff --git a/lto-plugin/ChangeLog b/lto-plugin/ChangeLog index 9336ac9255554b8cafa15a402402dca2cf793f6d..ccb61654e7cf68ce0319fa35ba35d9aff21d3b34 100644 --- a/lto-plugin/ChangeLog +++ b/lto-plugin/ChangeLog @@ -1,3 +1,8 @@ +2010-03-16 Dmitry Gorbachev <d.g.gorbachev@gmail.com> + + PR lto/43336 + * lto-plugin.c (cleanup_handler): Delete temporary output files. + 2010-01-11 Richard Guenther <rguenther@suse.de> PR lto/41569 diff --git a/lto-plugin/lto-plugin.c b/lto-plugin/lto-plugin.c index 2fb4f2a778261c47a6fe3b3171d6f94d2c84f0c9..97b7c0fdfecd27464cb869ada3e0e9f893b833a7 100644 --- a/lto-plugin/lto-plugin.c +++ b/lto-plugin/lto-plugin.c @@ -524,6 +524,7 @@ all_symbols_read_handler (void) static enum ld_plugin_status cleanup_handler (void) { + unsigned int i; int t; if (debug) @@ -541,6 +542,12 @@ cleanup_handler (void) check (t == 0, LDPL_FATAL, "could not unlink resolution file"); } + for (i = 0; i < num_output_files; i++) + { + t = unlink (output_files[i]); + check (t == 0, LDPL_FATAL, "could not unlink output file"); + } + free_2 (); return LDPS_OK; }