summaryrefslogtreecommitdiffstats
path: root/usr.bin
diff options
context:
space:
mode:
authorjoris <joris@openbsd.org>2017-05-31 16:18:20 +0000
committerjoris <joris@openbsd.org>2017-05-31 16:18:20 +0000
commit990ca81862b7e3adbfe7d4c150445fb431d4c0cd (patch)
treea106e2ced7eec82ac526271404652d94f97675b0 /usr.bin
parentfix indentation (diff)
downloadwireguard-openbsd-990ca81862b7e3adbfe7d4c150445fb431d4c0cd.tar.xz
wireguard-openbsd-990ca81862b7e3adbfe7d4c150445fb431d4c0cd.zip
When unlocking a directory only unlock the given one rather then all repo_locks.
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/cvs/repository.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/cvs/repository.c b/usr.bin/cvs/repository.c
index a5d0fa761ac..6f971e38763 100644
--- a/usr.bin/cvs/repository.c
+++ b/usr.bin/cvs/repository.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: repository.c,v 1.24 2015/01/16 06:40:07 deraadt Exp $ */
+/* $OpenBSD: repository.c,v 1.25 2017/05/31 16:18:20 joris Exp $ */
/*
* Copyright (c) 2006 Joris Vink <joris@openbsd.org>
*
@@ -36,8 +36,8 @@ cvs_repository_unlock(const char *repo)
(void)xsnprintf(fpath, sizeof(fpath), "%s/%s", repo, CVS_LOCK);
- /* XXX - this ok? */
- worklist_run(&repo_locks, worklist_unlink);
+ if (unlink(fpath) == -1 && errno != ENOENT)
+ cvs_log(LP_ERR, "warning: failed to unlink %s", fpath);
}
void