diff options
author | Jim Meyering <jim@meyering.net> | 2002-08-09 10:03:58 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2002-08-09 10:03:58 +0000 |
commit | b1113d0168cec6ae4c0f87072c23d217ed41f7c4 (patch) | |
tree | c87b2c32ec91f4901367da6d72a9b2a19e342382 /src | |
parent | 82e2664b873a84aa277048e7a7ad30eadb6e9423 (diff) | |
download | coreutils-b1113d0168cec6ae4c0f87072c23d217ed41f7c4.tar.xz |
(main): Don't ignore -COLUMN if it's the last option.
(usage): Clarify help text for the -COLUMN option.
Diffstat (limited to 'src')
-rw-r--r-- | src/pr.c | 14 |
1 files changed, 6 insertions, 8 deletions
@@ -46,7 +46,7 @@ - With single column output only one POSIX requirement has to be met: The default n-separator should be a TAB. The consequence is a - different width between the number an the text if the output position + different width between the number and the text if the output position of the separator changes, i.e. it depends upon the left margin used. That's not nice but easy-to-use together with the defaults of other utilities, e.g. sort or cut. - Same as SunOS does. @@ -878,16 +878,14 @@ main (int argc, char **argv) if (ISDIGIT (c)) { accum = accum * 10 + c - '0'; - continue; - } - - if (accum > 0) - { columns = accum; explicit_columns = TRUE; - accum = 0; + continue; } + if (accum > 0) /* reset for subsequent params */ + accum = 0; + switch (c) { case 0: /* getopt long option */ @@ -2769,7 +2767,7 @@ Mandatory arguments to long options are mandatory for short options too.\n\ +FIRST_PAGE[:LAST_PAGE], --pages=FIRST_PAGE[:LAST_PAGE]\n\ begin [stop] printing with page FIRST_[LAST_]PAGE\n\ -COLUMN, --columns=COLUMN\n\ - produce COLUMN-column output and print columns down,\n\ + output COLUMN columns and print columns down,\n\ unless -a is used. Balance number of lines in the\n\ columns on each page.\n\ "), stdout); |