summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjoris <joris@openbsd.org>2005-05-11 00:07:57 +0000
committerjoris <joris@openbsd.org>2005-05-11 00:07:57 +0000
commit580ceb6a3a247127e99b4fc5b30dcbf2b42b7eea (patch)
tree205de8bd8bf296496e11736a45c21462950ab542
parentenable arm optimized in4_cksum (diff)
downloadwireguard-openbsd-580ceb6a3a247127e99b4fc5b30dcbf2b42b7eea.tar.xz
wireguard-openbsd-580ceb6a3a247127e99b4fc5b30dcbf2b42b7eea.zip
in cvs_resp_removed(), don't abort the operation if we are trying
to unlink(2) a file that has already been removed. ok xsa@
-rw-r--r--usr.bin/cvs/resp.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/cvs/resp.c b/usr.bin/cvs/resp.c
index 59200b0432a..73248428044 100644
--- a/usr.bin/cvs/resp.c
+++ b/usr.bin/cvs/resp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: resp.c,v 1.31 2005/05/03 08:55:16 joris Exp $ */
+/* $OpenBSD: resp.c,v 1.32 2005/05/11 00:07:57 joris Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -705,7 +705,8 @@ cvs_resp_removed(struct cvsroot *root, int type, char *line)
cvs_ent_close(ef);
}
- if ((type == CVS_RESP_REMOVED) && (unlink(fpath) == -1)) {
+ if ((type == CVS_RESP_REMOVED) && ((unlink(fpath) == -1) &&
+ errno != ENOENT)) {
cvs_log(LP_ERRNO, "failed to unlink `%s'", file);
return (-1);
}