summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoris Vink <joris@cvs.openbsd.org>2009-04-03 19:46:57 +0000
committerJoris Vink <joris@cvs.openbsd.org>2009-04-03 19:46:57 +0000
commit1cc692ac6f0ec73df29cdc29aeb0eac74a7cb407 (patch)
tree0bb730029d23d6f1247571ab0ec14045889229a7
parent9577ead76e75820d29bf0aa5ddd39cfdedebf97e (diff)
i fucked up last night, bad so partially revert a piece of
code that wasnt suppose to dissapear: for uptodate files, we want to compare rev1 against file_rcsrev to see if we wish to diff or not. saves a bit off logic. commited with opencvs, permission by deraadt@
-rw-r--r--usr.bin/cvs/diff.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/usr.bin/cvs/diff.c b/usr.bin/cvs/diff.c
index 98c8dac4d81..2fdef195f97 100644
--- a/usr.bin/cvs/diff.c
+++ b/usr.bin/cvs/diff.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: diff.c,v 1.150 2009/04/03 08:18:44 joris Exp $ */
+/* $OpenBSD: diff.c,v 1.151 2009/04/03 19:46:56 joris Exp $ */
/*
* Copyright (c) 2008 Tobias Stoeckmann <tobias@openbsd.org>
* Copyright (c) 2006 Joris Vink <joris@openbsd.org>
@@ -410,6 +410,11 @@ cvs_diff_local(struct cvs_file *cf)
switch (cvs_cmdop) {
case CVS_OP_DIFF:
+ if (cf->file_status == FILE_UPTODATE) {
+ if (diff_rev2 == NULL &&
+ !rcsnum_cmp(diff_rev1, cf->file_rcsrev, 0))
+ goto cleanup;
+ }
break;
case CVS_OP_RDIFF:
if (diff_rev1 == NULL && diff_rev2 == NULL)