Subject: bin/30751: calendar -x falls into usage.
To: None <gnats-admin@netbsd.org, netbsd-bugs@netbsd.org>
From: None <m4nb@biff.mail-box.ne.jp>
List: netbsd-bugs
Date: 07/15/2005 02:43:00
>Number:         30751
>Category:       bin
>Synopsis:       calendar -x falls into usage.
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Jul 15 02:43:00 +0000 2005
>Originator:     YOMURA Masanori
>Release:        NetBSD 3.99.7
>Organization:
>Environment:
NetBSD lmm.localdomain 3.99.7 NetBSD 3.99.7 (CUSTOM) #7: Mon Jul  4 11:02:09 JST 2005  
root@lmm.localdomain:/fs/local/var/kern/compile/CUSTOM i386

>Description:
`calendar -x ' does not do anything, and falls into usage.

This bug is also in netbsd-3.
>How-To-Repeat:
% calendar -x
usage: calendar [-ax] [-d MMDD[[YY]YY] [-f fname] [-l days] [-w days]
%
>Fix:
--- /usr/src/usr.bin/calendar/calendar.c	2005-06-03 00:05:28.000000000 +0900
+++ calendar.c	2005-07-15 11:08:56.000000000 +0900
@@ -151,6 +151,7 @@
 			break;
 		case 'x':
 			cpp_restricted = 1;
+			break;
 		case '?':
 		default:
 			usage();