Subject: bin/26220: missing option in the usage of join(1)
To: None <gnats-bugs@gnats.NetBSD.org>
From: None <hira@po6.nsk.ne.jp>
List: netbsd-bugs
Date: 07/10/2004 13:03:43
>Number: 26220
>Category: bin
>Synopsis: missing option in the usage of join(1)
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people
>State: open
>Class: doc-bug
>Submitter-Id: net
>Arrival-Date: Sat Jul 10 04:04:00 UTC 2004
>Closed-Date:
>Last-Modified:
>Originator: Kouichirou Hiratsuka
>Release: NetBSD 2.0G
>Organization:
>Environment:
System: NetBSD firefly.localdomain 2.0G NetBSD 2.0G (FIREFLY.MP) #20: Fri Jul 9 01:13:02 JST 2004 root@firefly.localdomain:/usr/src/sys/arch/i386/compile/FIREFLY.MP i386
Architecture: i386
Machine: i386
>Description:
-j is missing in the usage of join(1).
>How-To-Repeat:
join
>Fix:
* add -j
* remove whitespace after -v
* sort options
* use getprogname(3)
Index: join/join.c
===================================================================
RCS file: /cvs/cvsroot/src/usr.bin/join/join.c,v
retrieving revision 1.24
diff -u -r1.24 join.c
--- join/join.c 16 Oct 2003 06:56:17 -0000 1.24
+++ join/join.c 9 Jul 2004 20:24:10 -0000
@@ -632,8 +632,9 @@
void
usage()
{
- (void)fprintf(stderr, "%s%s\n",
- "usage: join [-a fileno | -v fileno ] [-e string] [-1 field] ",
- "[-2 field]\n [-o list] [-t char] file1 file2");
+ (void)fprintf(stderr,
+ "usage: %s [-a fileno | -v fileno] [-e string] [-j fileno field]\n"
+ " [-o list] [-t char] [-1 field] [-2 field] file1 file2"
+ "\n", getprogname());
exit(1);
}
>Release-Note:
>Audit-Trail:
>Unformatted: