diff options
author | H.J. Lu <hongjiu.lu@intel.com> | 2008-11-25 15:01:41 +0000 |
---|---|---|
committer | H.J. Lu <hjl@gcc.gnu.org> | 2008-11-25 07:01:41 -0800 |
commit | 5308fd74fdb4e60b11866cadb5fdaa3e42809a1c (patch) | |
tree | f8d1ac892045853a83c6be7b6cd51a3d989e6fbb /gcc | |
parent | bc0f8bd47860ef185442971eb3e5cea226962ef5 (diff) | |
download | gcc-5308fd74fdb4e60b11866cadb5fdaa3e42809a1c.zip gcc-5308fd74fdb4e60b11866cadb5fdaa3e42809a1c.tar.gz gcc-5308fd74fdb4e60b11866cadb5fdaa3e42809a1c.tar.bz2 |
module.c (gfc_dump_module): Report error on unlink only if errno != ENOENT.
2008-11-25 H.J. Lu <hongjiu.lu@intel.com>
* module.c (gfc_dump_module): Report error on unlink only if
errno != ENOENT.
From-SVN: r142192
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/fortran/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/fortran/module.c | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/fortran/ChangeLog b/gcc/fortran/ChangeLog index b22c8da..a01ae8f 100644 --- a/gcc/fortran/ChangeLog +++ b/gcc/fortran/ChangeLog @@ -1,3 +1,8 @@ +2008-11-25 H.J. Lu <hongjiu.lu@intel.com> + + * module.c (gfc_dump_module): Report error on unlink only if + errno != ENOENT. + 2008-11-25 Mikael Morin <mikael.morin@tele2.fr> PR fortran/36463 diff --git a/gcc/fortran/module.c b/gcc/fortran/module.c index a49745a..1b32ee2 100644 --- a/gcc/fortran/module.c +++ b/gcc/fortran/module.c @@ -4850,7 +4850,7 @@ gfc_dump_module (const char *name, int dump_flag) || memcmp (md5_old, md5_new, sizeof (md5_old)) != 0) { /* Module file have changed, replace the old one. */ - if (unlink (filename)) + if (unlink (filename) && errno != ENOENT) gfc_fatal_error ("Can't delete module file '%s': %s", filename, strerror (errno)); if (rename (filename_tmp, filename)) |