diff options
author | Joris Vink <joris@cvs.openbsd.org> | 2005-12-09 06:59:28 +0000 |
---|---|---|
committer | Joris Vink <joris@cvs.openbsd.org> | 2005-12-09 06:59:28 +0000 |
commit | 7a2887037cef08e068e73132c69dfdefb5c7ef14 (patch) | |
tree | 7b66f3094285ea61c827bc7eb2c47df6823913f8 /usr.bin/rcs | |
parent | 335d8e78012676eb0db62d4e1209b74e22353e78 (diff) |
if we are removing a lock that's not present, just check
out the file without complaining;
Diffstat (limited to 'usr.bin/rcs')
-rw-r--r-- | usr.bin/rcs/co.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/usr.bin/rcs/co.c b/usr.bin/rcs/co.c index aee9a2c86d5..ed3ea8b4465 100644 --- a/usr.bin/rcs/co.c +++ b/usr.bin/rcs/co.c @@ -1,4 +1,4 @@ -/* $OpenBSD: co.c,v 1.45 2005/12/09 04:27:01 joris Exp $ */ +/* $OpenBSD: co.c,v 1.46 2005/12/09 06:59:27 joris Exp $ */ /* * Copyright (c) 2005 Joris Vink <joris@openbsd.org> * All rights reserved. @@ -301,8 +301,10 @@ checkout_rev(RCSFILE *file, RCSNUM *frev, const char *dst, int flags, if (verbose == 1) printf(" (locked)"); } else if (flags & CO_UNLOCK) { - if (rcs_lock_remove(file, lockname, frev) < 0) - return (-1); + if (rcs_lock_remove(file, lockname, frev) < 0) { + if (rcs_errno != RCS_ERR_NOENT) + return (-1); + } mode = 0444; if (verbose == 1) |