summaryrefslogtreecommitdiff
path: root/usr.bin/cvs/cvs.h
diff options
context:
space:
mode:
authorJoris Vink <joris@cvs.openbsd.org>2005-09-06 15:29:34 +0000
committerJoris Vink <joris@cvs.openbsd.org>2005-09-06 15:29:34 +0000
commit71442aed77bb01f56d28f6cbc9fdeb82acfe9212 (patch)
tree35b9ff888169a577e220f0a931adb7cf93123088 /usr.bin/cvs/cvs.h
parent68ccf787a8ec4f3499e320c5c4fdb8b8bb01406e (diff)
Make sure entries do not go away when we run through them in the file code.
Fixes corrupt Entry files. Problem found by Mike Pechkin, thanks.
Diffstat (limited to 'usr.bin/cvs/cvs.h')
-rw-r--r--usr.bin/cvs/cvs.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/usr.bin/cvs/cvs.h b/usr.bin/cvs/cvs.h
index ec2491d05a3..9498cfb1503 100644
--- a/usr.bin/cvs/cvs.h
+++ b/usr.bin/cvs/cvs.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: cvs.h,v 1.81 2005/09/05 19:29:42 xsa Exp $ */
+/* $OpenBSD: cvs.h,v 1.82 2005/09/06 15:29:33 joris Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -260,6 +260,13 @@ struct cvs_ent {
time_t ce_mtime;
char *ce_opts;
char *ce_tag;
+
+ /*
+ * This variable is set to 1 if we have already processed this entry
+ * in the cvs_file_getdir() function. This is to avoid files being
+ * passed twice to the callbacks.
+ */
+ int processed;
TAILQ_ENTRY(cvs_ent) ce_list;
};