diff options
author | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-11-22 21:18:15 +0000 |
---|---|---|
committer | jsm28 <jsm28@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-11-22 21:18:15 +0000 |
commit | a1051b025260d4d81bc8e291ac10eeee6f5ad6ab (patch) | |
tree | ca7690ade68532db217ac84a27e4fb2d67fbfac7 /gcc/gcc.c | |
parent | 76c33df9bce661936ce175002a666ff31230e66d (diff) | |
download | gcc-a1051b025260d4d81bc8e291ac10eeee6f5ad6ab.tar.gz |
2010-11-22 Dmitry Gorbachev <d.g.gorbachev@gmail.com>
PR driver/43335
* gcc.c (main): Don't crash when lto-wrapper program is not found.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@167052 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/gcc.c')
-rw-r--r-- | gcc/gcc.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/gcc/gcc.c b/gcc/gcc.c index fb981716b2e..99d4f480d56 100644 --- a/gcc/gcc.c +++ b/gcc/gcc.c @@ -6074,6 +6074,7 @@ main (int argc, char **argv) int num_linker_inputs = 0; char *explicit_link_files; char *specs_file; + char *lto_wrapper_file; const char *p; struct user_specs *uptr; char **old_argv = argv; @@ -6412,9 +6413,10 @@ main (int argc, char **argv) /* Set up to remember the pathname of the lto wrapper. */ - lto_wrapper_spec = find_a_file (&exec_prefixes, "lto-wrapper", X_OK, false); - if (lto_wrapper_spec) + lto_wrapper_file = find_a_file (&exec_prefixes, "lto-wrapper", X_OK, false); + if (lto_wrapper_file) { + lto_wrapper_spec = lto_wrapper_file; obstack_init (&collect_obstack); obstack_grow (&collect_obstack, "COLLECT_LTO_WRAPPER=", sizeof ("COLLECT_LTO_WRAPPER=") - 1); |