summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjoris <joris@openbsd.org>2008-06-12 16:54:46 +0000
committerjoris <joris@openbsd.org>2008-06-12 16:54:46 +0000
commit629c41f70be86f57c7f4ab93c9b38102891c1f5e (patch)
treec97fd2294a84a0c4a431bfbb334f64a19c7d6fad
parentcmdp can be NULL while still in cvs_getopt(), so deal with this (diff)
downloadwireguard-openbsd-629c41f70be86f57c7f4ab93c9b38102891c1f5e.tar.xz
wireguard-openbsd-629c41f70be86f57c7f4ab93c9b38102891c1f5e.zip
properly deal with CVS_USE_WDIR.
ok tobias@
-rw-r--r--usr.bin/cvs/file.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/cvs/file.c b/usr.bin/cvs/file.c
index db9683263a5..d13aa54734c 100644
--- a/usr.bin/cvs/file.c
+++ b/usr.bin/cvs/file.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: file.c,v 1.244 2008/06/12 07:29:54 joris Exp $ */
+/* $OpenBSD: file.c,v 1.245 2008/06/12 16:54:46 joris Exp $ */
/*
* Copyright (c) 2006 Joris Vink <joris@openbsd.org>
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
@@ -294,7 +294,8 @@ cvs_file_walklist(struct cvs_flisthead *fl, struct cvs_recursion *cr)
* During checkout -p, do not use any locally
* available directories.
*/
- if (cvs_cmdop != CVS_OP_CHECKOUT && !print_stdout)
+ if ((cmdp->cmd_flags & CVS_USE_WDIR) &&
+ (cvs_cmdop != CVS_OP_CHECKOUT || !print_stdout))
if (stat(d, &st) == -1) {
cvs_log(LP_ERRNO, "%s", d);
goto next;