lto-wrapper.c (maybe_unlink_file): Ignore unlink failure for non-existant files.

2010-05-27  Richard Guenther  <rguenther@suse.de>

	* lto-wrapper.c (maybe_unlink_file): Ignore unlink failure
	for non-existant files.
	(fork_execute): Mark args_name file as deleted.

From-SVN: r159913
This commit is contained in:
Richard Guenther 2010-05-27 10:33:08 +00:00 committed by Richard Biener
parent 64c3178544
commit 62116e601b
2 changed files with 10 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2010-05-27 Richard Guenther <rguenther@suse.de>
* lto-wrapper.c (maybe_unlink_file): Ignore unlink failure
for non-existant files.
(fork_execute): Mark args_name file as deleted.
2010-05-27 Kai Tietz <kai.tietz@onevision.com>
PR bootstrp/44287

View File

@ -39,6 +39,7 @@ along with GCC; see the file COPYING3. If not see
#include "config.h"
#include "system.h"
#include <errno.h>
#include "coretypes.h"
#include "tm.h"
#include "intl.h"
@ -222,7 +223,8 @@ maybe_unlink_file (const char *file)
{
if (! debug)
{
if (unlink_if_ordinary (file))
if (unlink_if_ordinary (file)
&& errno != ENOENT)
fatal_perror ("deleting LTRANS file %s", file);
}
else
@ -262,6 +264,7 @@ fork_execute (char **argv)
collect_wait (new_argv[0], pex);
maybe_unlink_file (args_name);
args_name = NULL;
free (at_args);
}