diff options
author | Ray Lai <ray@cvs.openbsd.org> | 2006-03-24 05:14:49 +0000 |
---|---|---|
committer | Ray Lai <ray@cvs.openbsd.org> | 2006-03-24 05:14:49 +0000 |
commit | 80fcb5d370cf852c06beef2ad10204c3cecd42d4 (patch) | |
tree | 7554f8bb91dd856c693d86ab2b2822d084127d18 /usr.bin/rcs/rcsclean.c | |
parent | 2bf0aa5f5911d76099d160802d34f1a621efcde6 (diff) |
Allow the -x flag to be used without an extension.
``that makes sense'' xsa@
Diffstat (limited to 'usr.bin/rcs/rcsclean.c')
-rw-r--r-- | usr.bin/rcs/rcsclean.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.bin/rcs/rcsclean.c b/usr.bin/rcs/rcsclean.c index 072a6da1ee8..4905e167482 100644 --- a/usr.bin/rcs/rcsclean.c +++ b/usr.bin/rcs/rcsclean.c @@ -1,4 +1,4 @@ -/* $OpenBSD: rcsclean.c,v 1.26 2006/03/16 04:04:57 ray Exp $ */ +/* $OpenBSD: rcsclean.c,v 1.27 2006/03/24 05:14:48 ray Exp $ */ /* * Copyright (c) 2005 Joris Vink <joris@openbsd.org> * All rights reserved. @@ -46,7 +46,7 @@ rcsclean_main(int argc, char **argv) rev = RCS_HEAD_REV; - while ((ch = rcs_getopt(argc, argv, "k:n::q::r:Tu::Vx:")) != -1) { + while ((ch = rcs_getopt(argc, argv, "k:n::q::r:Tu::Vx::")) != -1) { switch (ch) { case 'k': kflag = rcs_kflag_get(rcs_optarg); @@ -80,7 +80,8 @@ rcsclean_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; default: break; |