summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdam Jackson <ajax@redhat.com>2016-01-06 10:03:23 -0500
committerAdam Jackson <ajax@redhat.com>2016-01-06 12:23:31 -0500
commit6dcb73375e0ce389315d55587623eb84e9d13543 (patch)
tree3a16068d57141ec0d0ab95e69ddc3468fd405547
parent862cbf4c870c9ed913206c6ef4988bdb470e1c39 (diff)
downloadxserver-6dcb73375e0ce389315d55587623eb84e9d13543.tar.gz
os: Failure to remove a non-existent log file is not an error
Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--os/log.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/os/log.c b/os/log.c
index 6168d59bd..91e55a532 100644
--- a/os/log.c
+++ b/os/log.c
@@ -218,7 +218,7 @@ LogFilePrep(const char *fname, const char *backup, const char *idstring)
}
}
else {
- if (remove(logFileName) != 0) {
+ if (remove(logFileName) != 0 && errno != ENOENT) {
FatalError("Cannot remove old log file \"%s\": %s\n",
logFileName, strerror(errno));
}