summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Stoeckmann <tobias@cvs.openbsd.org>2008-02-09 12:27:32 +0000
committerTobias Stoeckmann <tobias@cvs.openbsd.org>2008-02-09 12:27:32 +0000
commit84d1ffc5eee1d945dd9c08e0fbdcbecb2a51a567 (patch)
treeec14097609748b6f520240df474e0751e0f2ffe9
parentef70301b27bc8c9a97083d9faa9a09e12da84bfa (diff)
If run as server, (r)diff should properly write (r)diff into header
instead of "server". OK joris@
-rw-r--r--usr.bin/cvs/diff.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/cvs/diff.c b/usr.bin/cvs/diff.c
index bc476e14066..2e3b196bf10 100644
--- a/usr.bin/cvs/diff.c
+++ b/usr.bin/cvs/diff.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: diff.c,v 1.127 2008/02/04 21:25:32 tobias Exp $ */
+/* $OpenBSD: diff.c,v 1.128 2008/02/09 12:27:31 tobias Exp $ */
/*
* Copyright (c) 2006 Joris Vink <joris@openbsd.org>
*
@@ -65,7 +65,8 @@ cvs_diff(int argc, char **argv)
struct cvs_recursion cr;
flags = CR_RECURSE_DIRS;
- strlcpy(diffargs, argv[0], sizeof(diffargs));
+ strlcpy(diffargs, cvs_cmdop == CVS_OP_DIFF ? "diff" : "rdiff",
+ sizeof(diffargs));
while ((ch = getopt(argc, argv, cvs_cmdop == CVS_OP_DIFF ?
cvs_cmd_diff.cmd_opts : cvs_cmd_rdiff.cmd_opts)) != -1) {