summaryrefslogtreecommitdiff
path: root/usr.bin/cvs
diff options
context:
space:
mode:
authorJoris Vink <joris@cvs.openbsd.org>2005-05-24 21:57:34 +0000
committerJoris Vink <joris@cvs.openbsd.org>2005-05-24 21:57:34 +0000
commite13ede6f2cdaed90d7178c571a7dfbc37ad5bf09 (patch)
tree31c369829ee0a5dc1b2bb0918419c1ed174b76b4 /usr.bin/cvs
parent6b350f03ed74eaac33de56f10b13f534e36df59d (diff)
don't fail on mkdir(2) when errno is EEXIST in cvs_file_create().
Diffstat (limited to 'usr.bin/cvs')
-rw-r--r--usr.bin/cvs/file.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/cvs/file.c b/usr.bin/cvs/file.c
index f109e3fb599..6aec3167b38 100644
--- a/usr.bin/cvs/file.c
+++ b/usr.bin/cvs/file.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: file.c,v 1.78 2005/05/24 20:04:43 joris Exp $ */
+/* $OpenBSD: file.c,v 1.79 2005/05/24 21:57:33 joris Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -269,7 +269,7 @@ cvs_file_create(CVSFILE *parent, const char *path, u_int type, mode_t mode)
return (NULL);
}
- if ((mkdir(path, mode) == -1) ||
+ if (((mkdir(path, mode) == -1) && (errno != EEXIST)) ||
(cvs_mkadmin(path, cfp->cf_root->cr_str, cfp->cf_repo) < 0)) {
cvs_file_free(cfp);
return (NULL);