From: Sylvestre Ledru Date: Fri, 30 Jun 2017 14:17:54 +0000 (+0000) Subject: * lto-wrapper.c (copy_file) Close both file descriptors before X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=367e91e1c5c293da8d0999cb2bc5d8cd2c95e6b4;p=gcc.git * lto-wrapper.c (copy_file) Close both file descriptors before exiting normally. From-SVN: r249841 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d6a709b617e..84a93992292 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2017-06-30 Sylvestre Ledru + + * lto-wrapper.c (copy_file) Close both file descriptors before + exiting normally. + 2017-06-30 Martin Liska PR ipa/81214 diff --git a/gcc/lto-wrapper.c b/gcc/lto-wrapper.c index 4b86f939ca2..832ffde3e40 100644 --- a/gcc/lto-wrapper.c +++ b/gcc/lto-wrapper.c @@ -838,6 +838,8 @@ copy_file (const char *dest, const char *src) fatal_error (input_location, "writing output file"); } } + fclose (d); + fclose (s); } /* Find the crtoffloadtable.o file in LIBRARY_PATH, make copy and pass name of