summaryrefslogtreecommitdiff
path: root/usr.bin/rcs/rcsmerge.c
diff options
context:
space:
mode:
authorRay Lai <ray@cvs.openbsd.org>2006-03-24 05:14:49 +0000
committerRay Lai <ray@cvs.openbsd.org>2006-03-24 05:14:49 +0000
commit80fcb5d370cf852c06beef2ad10204c3cecd42d4 (patch)
tree7554f8bb91dd856c693d86ab2b2822d084127d18 /usr.bin/rcs/rcsmerge.c
parent2bf0aa5f5911d76099d160802d34f1a621efcde6 (diff)
Allow the -x flag to be used without an extension.
``that makes sense'' xsa@
Diffstat (limited to 'usr.bin/rcs/rcsmerge.c')
-rw-r--r--usr.bin/rcs/rcsmerge.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.bin/rcs/rcsmerge.c b/usr.bin/rcs/rcsmerge.c
index 54f90713566..61679e4998b 100644
--- a/usr.bin/rcs/rcsmerge.c
+++ b/usr.bin/rcs/rcsmerge.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rcsmerge.c,v 1.22 2006/03/23 08:50:41 xsa Exp $ */
+/* $OpenBSD: rcsmerge.c,v 1.23 2006/03/24 05:14:48 ray Exp $ */
/*
* Copyright (c) 2005, 2006 Xavier Santolaria <xsa@openbsd.org>
* All rights reserved.
@@ -42,7 +42,7 @@ rcsmerge_main(int argc, char **argv)
baserev = rev2 = RCS_HEAD_REV;
- while ((ch = rcs_getopt(argc, argv, "AEek:p::q::r:TVx:z:")) != -1) {
+ while ((ch = rcs_getopt(argc, argv, "AEek:p::q::r:TVx::z:")) != -1) {
switch (ch) {
case 'A': case 'E': case 'e':
break;
@@ -81,7 +81,8 @@ rcsmerge_main(int argc, char **argv)
exit(0);
/* NOTREACHED */
case 'x':
- rcs_suffixes = rcs_optarg;
+ /* Use blank extension if none given. */
+ rcs_suffixes = rcs_optarg ? rcs_optarg : "";
break;
case 'z':
timezone_flag = rcs_optarg;