Jim Meyering
7e76b8b7da
(usage): Give minimal description of the program.
...
(print_factors): Give a better diagnostic.
(main): Suggest --help upon failure.
Reported by Karl Eichwalder <ke@ke.Central.DE >.
1996-04-07 17:46:03 +00:00
Jim Meyering
d9fe359377
.
1996-04-07 17:27:27 +00:00
Jim Meyering
c32c5775be
Fiddle with messages.
1996-04-07 17:27:11 +00:00
Jim Meyering
3220407d48
(print_numbers): Give more precise diagnostic when increment
...
is inconsistent with FROM and TO.
(usage): Clean up help message.
1996-04-07 17:10:21 +00:00
Jim Meyering
45c51b256a
(main): Rearrange loops to get it right.
...
Reported by Karl Eichwalder <ke@ke.Central.DE >.
1996-04-07 16:59:12 +00:00
Jim Meyering
78732c5421
Remove diagnostic.
1996-04-05 16:04:15 +00:00
Jim Meyering
0e199278c1
(main): Use `if' stmt, not while loop, around getopt invocation.
...
Otherwise, `./nice --a=1 -1 ./nice' (in which old-style option
follows a long option) gets an error.
1996-04-05 13:32:39 +00:00
Jim Meyering
9d22ab92f9
Patch from Frank Korz.
1996-04-05 13:14:59 +00:00
Jim Meyering
43b84ec02e
Remove fixed FIXME.
1996-04-05 04:00:05 +00:00
Jim Meyering
987f70fee5
.
1996-04-04 23:10:35 +00:00
Jim Meyering
42a0e84308
The following commands all failed unnecessarily.
...
tr -cs '[:upper:]' '[X*]'
tr -dcs '[:lower:]' n-rs-z
tr -ds '[:xdigit:]' [:alnum:]'
tr -dcs '[:alnum:]' [:digit:]'
tr -dc '[:upper:]'
Reported by Ross Ridge (ross@worf.mks.com ).
(validate): Add missing conjunct (translating) in test for
`translating and complementing character classes' error. Before,
valid uses of tr could fail. E.g. `tr -dcs '[:cntrl:]' '[:alnum:]''.
(homogeneous_spec_list): New function.
(validate): Use it to relax the old (overly restrictive) restriction
that prohibited use of complemented character classes when translating.
Now, that is allowed as long as the translation maps many to one.
(get_spec_stats): Rename and redefine global has_char_class from
has_upper_or_lower.
1996-04-04 23:08:30 +00:00
Jim Meyering
3191649a85
(copy_reg): Use ST_NBLOCKS (sb) * 512', not sb.st_blocks *
...
DEV_BSIZE.' From H.J. Lu (hjl@lucon.org ).
1996-04-03 12:20:24 +00:00
Jim Meyering
4325d27ddd
Include assert.h (disabled).
...
(path_concat): New function.
(do_copy): Use path_concat instead of open-coding part of its
functionality in two places. This has the additional benefit
of avoiding forming destination names like `D//file' when the
destination directory D includes a trailing slash -- as would
happen when cp is used like this:
mkdir D; touch file D/file; cp -i file D/
Reported by François Pinard.
1996-04-03 05:42:14 +00:00
Jim Meyering
3d1c60aba7
.
1996-03-31 17:19:06 +00:00
Jim Meyering
399abab9bc
(quote_filename): Use ISGRAPH and ISPRINT in place of
...
ASCII-centric tests against literals.
(length_of_file_name_and_frills): Likewise.
1996-03-31 17:18:28 +00:00
Jim Meyering
908040f25e
Rip out color support.
1996-03-31 14:22:12 +00:00
Jim Meyering
c2efd628df
.
1996-03-29 04:53:57 +00:00
Jim Meyering
fee163dd57
Move usage to precede main.
...
Say `too few arguments' if that's why we display usage.
Protoize.
Include error.h.
Update copyright.
1996-03-28 06:17:34 +00:00
Jim Meyering
0271d97259
from Roland
1996-03-28 05:42:56 +00:00
Jim Meyering
7c5f9f7faa
(cksum): Use format "%lu %ld" (instead of "%10lu %8ld")
...
to be POSIX compliant. From Stephen Gildea <gildea@x.org >.
1996-03-28 05:35:31 +00:00
Jim Meyering
5de0b392f2
Update FSF's address.
1996-03-24 18:47:09 +00:00
Jim Meyering
3613700a38
Update FSF's address.
1996-03-24 18:40:53 +00:00
Jim Meyering
318a497768
Update FSF's address.
1996-03-24 18:33:12 +00:00
Jim Meyering
f9714aa24d
Include xstrtod.h.
...
(scan_double_arg): Use xstrtod rather than strtod directly.
1996-03-24 18:16:10 +00:00
Jim Meyering
236c02759b
Make parameters const where appropriate.
...
Rename global FROM to START.
(print_numbers): Rewrite loops to avoid incrementing. Instead,
use `x = first + i * increment' paradigm. Otherwise, with inexact
increment, you could miss the last value.
1996-03-24 17:50:09 +00:00
Jim Meyering
777948e773
Protoize and reorder functions.
1996-03-24 17:43:41 +00:00
Jim Meyering
6e45576dd6
(main): Reformat if-block a little.
...
Declare index I to be of type size_t to avoid warning from gcc -Wall.
1996-03-24 17:21:40 +00:00
Jim Meyering
818d29db9b
Call error with EXIT_FAILURE (rather than `1') as first actual parameter.
1996-03-24 16:59:11 +00:00
Jim Meyering
47f70113d4
Exit with status EXIT_SUCCESS or EXIT_FAILURE, rather than 0 or 1.
...
This doesn't change `error (1' calls.
1996-03-24 14:58:01 +00:00
Jim Meyering
e6fae6c23f
[SORT_FAILURE]: New macro.
...
Be careful to exit with 1 only when -c is used and the
input is not properly sorted. In all other cases, use
SORT_FAILURE as required by POSIX.
(main): Change some `error (1, ...' to use SORT_FAILURE.
Upon successful termination, exit with EXIT_SUCCESS instead of `0'.
Replace all uses of `2' (as exit code) with SORT_FAILURE.
1996-03-24 02:26:21 +00:00
Jim Meyering
7178674807
Include assert.h, but disable assertions.
...
(process_line_count): Replace if-abort with a slightly relaxed
assertion. Before, `echo |csplit - 1 1' would abort.
Reported by Samuli.Karkkainen@hut.fi .
(parse_patterns): Disallow uses like `csplit FILE 0' with zero
line number, `csplit FILE 2 1' with decreasing line numbers, and
warn about uses like `csplit FILE 3 3' that have equal line numbers.
1996-03-22 04:54:46 +00:00
Jim Meyering
1954f681c6
(main): Declare to be of type int, not void.
1996-03-21 22:47:02 +00:00
Jim Meyering
bb6a548712
(main): Declare to be of type int, not void.
1996-03-21 22:45:19 +00:00
Jim Meyering
adb7c216b2
(main): Declare to be of type int, not void.
1996-03-21 22:41:04 +00:00
Jim Meyering
dd5db06467
(main): Declare to return int, not void. From Peter Seebach
...
<seebs@taniemarie.solon.com >.
1996-03-21 13:00:15 +00:00
Jim Meyering
4229a555fc
Don't include version.h.
...
(main): Use PACKAGE_VERSION instead of version_string.
1996-03-16 22:30:54 +00:00
Jim Meyering
ca0246a4c1
Don't include version.h.
...
(main): Use PACKAGE_VERSION instead of version_string.
1996-03-16 16:49:28 +00:00
Jim Meyering
c1cdafa1b4
Change @VERSION@ to @PKG_VERSION@.
1996-03-16 16:41:36 +00:00
Jim Meyering
3ee97d4d5b
Don't include version.h.
...
(main): Use PACKAGE_VERSION instead of version_string.
1996-03-16 16:14:26 +00:00
Jim Meyering
2e5cc5e04e
(read_utmp): Declare n_read to be of type size_t rather than int.
1996-03-16 05:44:02 +00:00
Jim Meyering
182c784a99
(validate_path): Cast path_max to size_t before
...
comparing with strlen(path).
1996-03-16 05:43:24 +00:00
Jim Meyering
b14b621029
Remove __P-protected prototype for basename.
...
Reported by François Pinard.
(remove_suffix): Move to precede use. Remove prototype.
Declare formal parameter SUFFIX to be const.
1996-03-16 05:42:53 +00:00
Jim Meyering
6fc4ae7a28
(main): Initialize for internationalized message support:
...
call setlocale, bindtextdomain, and textdomain.
1996-03-12 23:49:29 +00:00
Jim Meyering
fe456215a6
[_]: Don't define this away.
1996-03-12 04:02:07 +00:00
Jim Meyering
10c96c43ac
(main): Initialize for internationalized message support: call setlocale,
...
bindtextdomain, and textdomain.
1996-03-12 03:08:30 +00:00
Jim Meyering
8e8fd5439a
Add definitions and includes for NLS.
1996-03-12 03:06:47 +00:00
Jim Meyering
6526b37460
(write_bytes): Renamed from xfwrite.
...
Remove SIZE parameter. It was always 1.
Update all callers.
Rename NELEM parameter to N_BYTES and change its type to size_t.
1996-03-11 22:07:21 +00:00
Jim Meyering
f090816a3f
(star_digits_closebracket): Declare formal param, IDX, and local I to
...
be of type size_t (rather than int) to avoid warnings from gcc -Wall.
1996-03-09 20:25:29 +00:00
Jim Meyering
d385bbc985
(memcasecmp): Declare local I to be unsigned to avoid warning from gcc -Wall.
1996-03-09 20:24:01 +00:00
Jim Meyering
715765a548
(main): Initialize for internationalized message support: call setlocale,
...
bindtextdomain, and textdomain.
1996-03-09 20:19:13 +00:00