summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoris Vink <joris@cvs.openbsd.org>2007-01-20 01:31:04 +0000
committerJoris Vink <joris@cvs.openbsd.org>2007-01-20 01:31:04 +0000
commit31d17019c2911ac0469067ceb1d741c569c0558e (patch)
tree2f13f3600f3e8491ac8f1b0efb905b8d334e71c0
parent33547e991a0d7e9aba396e4c1bb8fa46a2085bd4 (diff)
more safety checks for file->file_rcsrev;
'cool' niallo@
-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 5aed4420741..79b048d2d9a 100644
--- a/usr.bin/cvs/file.c
+++ b/usr.bin/cvs/file.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: file.c,v 1.172 2007/01/20 00:58:19 niallo Exp $ */
+/* $OpenBSD: file.c,v 1.173 2007/01/20 01:31:03 joris Exp $ */
/*
* Copyright (c) 2006 Joris Vink <joris@openbsd.org>
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
@@ -716,7 +716,7 @@ cvs_file_classify(struct cvs_file *cf, const char *tag, int loud)
ismodified = 0;
}
- if (cf->file_rcs != NULL) {
+ if (cf->file_rcs != NULL && cf->file_rcsrev != NULL) {
state = rcs_state_get(cf->file_rcs, cf->file_rcsrev);
if (state == NULL)
fatal("failed to get state for HEAD for %s",