[Bug 292408] synopsis of wc command
- Reply: bugzilla-noreply_a_freebsd.org: "[Bug 292408] synopsis of wc command"
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Mon, 12 Jan 2026 15:02:41 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=292408
Bug ID: 292408
Summary: synopsis of wc command
Product: Documentation
Version: Latest
Hardware: Any
OS: Any
Status: New
Severity: Affects Many People
Priority: ---
Component: Manual Pages
Assignee: bugs@FreeBSD.org
Reporter: sebastian.2013@ritter.biz
CC: doc@FreeBSD.org
(so less priority as available)
The synopsis of wc command is not correct, because c and m flag are not
together usable.
Manual file part...
SYNOPSIS
wc [--libxo] [-Lclmw] [file ...]
...
-c ... This will cancel out any prior usage of the -m option.
...
-m ... This will cancel out any prior usage of the -c option.
This is different to GNU implementation, because GNU wc supports both flags
together. But the problem is only the not clarify SYNOPSIS or the
implementation allow both together
Source code part /usr/bin/wc/wc.c lines 104 / 111:
while ((ch = getopt(argc, argv, "clmwL")) != -1)
switch((char)ch) {
case 'l':
doline = true;
break;
case 'w':
doword = true;
break;
case 'c':
dochar = true;
domulti = false;
break;
case 'L':
dolongline = true;
break;
case 'm':
domulti = true;
dochar = false;
break;
case '?':
default:
usage();
}
--
You are receiving this mail because:
You are the assignee for the bug.