Commit Graph
761 Commits
Author SHA1 Message Date
Jim Meyering 8ddd60a387 (copy): Comment change to avoid overwriting source with backup. 1996-03-09 04:59:22 +00:00
Jim Meyering ff6400a018 (main): Tell read_filesystem_list that it should determine file system type
when the user specifies --print-type or -T.  From Michael Rendell
<michael@cs.mun.ca>
1996-03-08 02:25:40 +00:00
Jim Meyering a74458a36e (print_entry): Use STRUCT_UTMP, not `struct utmp'. 1996-03-07 03:41:22 +00:00
Jim Meyering c239e82816 (usage): Reorder --time and --help so --help is the latter (just
before --version) to be consistent with other usage functions.
1996-03-06 05:04:05 +00:00
Jim Meyering b21af8a7dd (main): Exit after processing --version. 1996-03-05 05:47:04 +00:00
Jim Meyering 815b5ca1d5 (WINDOWS_SETFILEMODE_BINARY): New macro.
(skip) [_WIN32 && _O_BINARY]: Use it.
(read_char): Likewise.
(read_block): Likewise.
Based on changes by Gary Newman <gnewman@shore.net>.
1996-03-02 05:45:45 +00:00
Jim Meyering 3d2a9041f9 (docolon): Don't use deceptively-named RE_SYNTAX_POSIX_BASIC -- it recognizes
non-BRE \?, \+, and \|.  Instead, use RE_SYNTAX_POSIX_MINIMAL_BASIC.
1996-03-02 02:45:20 +00:00
Jim Meyering 446976666c General cleanup. Use xstrtoul, not atoi.
Change output format.  Allow inputs as large as ULONG_MAX.
Allow more than one command line argument.
1996-02-29 05:07:34 +00:00
Jim Meyering 557514f55c (wrapf) [!__STDC__]: Indent by one space the first line of the pre-ANSI
function definition so ansi2knr doesn't munge it.
1996-02-29 03:06:10 +00:00
Jim Meyering 9a181424ac (eval6): Cast strlen to int to avoid warning from gcc -Wall. 1996-02-29 02:53:37 +00:00
Jim Meyering edac0ff420 (copy): Remove bogus (now that we're using full_write) increment of w_partial.
Change sense of the tests (though they're equivalent) that check
the value returned by full_write. making it clearer where errno
is valid.  full_write always writes the full amount or fails.
1996-02-27 03:24:31 +00:00
Jim Meyering a4d2c17357 . 1996-02-25 12:55:48 +00:00
Jim Meyering 6f37efd8b2 (batch_convert): Put `' around filename in error in case it's empty. 1996-02-25 05:31:26 +00:00
Jim Meyering b12057e3bd __P-protect forward declarations.
(main): Protoize function definition.
1996-02-24 18:27:11 +00:00
Jim Meyering 34e1cf8304 (cmpf): Indent macro uses so ansi2knr doesn't mistake them
for function dcls and munge them.
(arithf): Likewise.
(arithdivf): Likewise.
1996-02-24 18:25:29 +00:00
Jim Meyering 85f9983c19 (docolon): Set re_syntax_options to RE_SYNTAX_POSIX_BASIC
so expr's pattern matching uses BASIC (not GNU-extended) REs.
Reported by Jim Kingdon.
1996-02-23 16:13:53 +00:00
Jim Meyering 9cb56e2980 (print_entry): Use strchr, not index. 1996-02-23 16:12:01 +00:00
Jim Meyering c5134a9b13 (batch_convert): Declare BUFLEN local to be of type size_t, not int. 1996-02-23 16:11:14 +00:00
Jim Meyering 756fe67e60 (xfields) [without -t]: Ignore leading blanks.
From David Dyck	(dcd@tc.fluke.COM).
1996-02-22 00:58:12 +00:00
Jim Meyering 28a24ea3be [TOLOWER]: Define.
(usage): Briefly describe new --ignore-case (-i) option.
(memcasecmp): New function.
(main): Set IGNORE_CASE for -i.
(keycmp): Compare with memcasecmp if IGNORE_CASE is set.
Suggestion and an initial patch from Alberto Accomazzi
<alberto@cfa0.harvard.edu>.
1996-02-18 18:08:01 +00:00
Jim Meyering 1f37d82ce4 Add -z option. Change all occurrences of '\n' to `eolchar'.
(usage): Describe it.
(main): Set eolchar to 0 for -z.
From Mark W. Eichin <eichin@cygnus.com>.
1996-02-18 00:55:08 +00:00
Jim Meyering 73d5e9c5dd Mark a few error strings for translation.
From Franc,ois Pinard.
1996-02-17 03:42:26 +00:00
Jim Meyering 816194943b (copy): Detect (and fail) when creating backup file would destroy source.
Reported by Martin C. Martin <mcm@cs.cmu.edu>.
1996-02-16 05:08:04 +00:00
Jim Meyering dd05029135 (main): When failing because there were `too many arguments,' say so. 1996-02-14 05:48:48 +00:00
Jim Meyering 0b2ebf9875 (print_entry): If possible, canonicalize the host hame.
From Miles Bader (miles@gnu.ai.mit.edu).
1996-02-13 05:27:16 +00:00
Jim Meyering 58e02de834 [.TRUE]: Undefine before defining.
[FALSE]: Undefine before defining.
From Derek Clegg (dclegg@next.com).
1996-02-13 03:12:52 +00:00
Jim Meyering 41d5fb8189 (main): Decalare local, BS. 1996-02-01 06:16:57 +00:00
Jim Meyering 46505987ea (main): Accept new option, --rfc-822 (-R).
(show_date): Use RFC822-mandated strftime format.
From H. Peter Anvin (hpa@storm.net).
(usage): Add a line describing the new option.
1996-02-01 05:44:59 +00:00
Jim Meyering e76eb59d84 (main): New options --human-readable (-h) and --megabytes (-m).
(human_readable_1k_blocks): New function.
(print_header): Honor new options.
(show_dev): Honor new options.
Add ifdef'd-out code to avoid printing lines for mount points that
match ^/auto/.* and ^/tmp_mnt.*.  Rather than hard-coding those
two prefixes, the code should allow the user to specify a regular
expression.  From Larry McVoy (lm@sgi.com).

(human_readable_1k_blocks): Likewise
(usage): Update usage message to reflect additions.
1996-02-01 05:30:14 +00:00
Jim Meyering a468d7579f (dump_remainder): Flush stdout when tailing-forever on multiple files.
From Carlos Canau <Carlos.Canau@relay.puug.pt>.
1996-02-01 05:25:54 +00:00
Jim Meyering 3b69e6514c Remove comma after last item in enum.
(human_readable): Fix off-by-one error that converted
1024*1024 to 1024K rather than 1G.  Describe the function.
1996-02-01 04:13:26 +00:00
Jim Meyering 9018ec3d41 (skip): Change type of parameter #5 from char* to unsigned char* to match
type of argument.
(copy): Cast first arg in memset call to char* to avoid warnings from
SunOS's acc.
(copy_simple): Likewise.
1996-02-01 03:50:06 +00:00
Jim Meyering 7bfb13dea7 Tweak usage. 1996-01-20 14:27:56 +00:00
Jim Meyering 744d31d57a (main): New options --human-readable (-h) and --megabytes (-m).
(human_readable): New function.
From Larry McVoy (lm@sgi.com).
1996-01-20 14:26:04 +00:00
Jim Meyering 156a61c86d (usage): Copy backup/suffix stuff from ln.c.
(main): Handle 'S' in getopt switch.
1996-01-20 12:37:12 +00:00
Jim Meyering c3e64b1b2d (copy_files): Accept backup options just as cp, ln, and
mv do: --backup (-b).  From Marty Leisner <leisner@sdsp.mc.xerox.c>.
1996-01-19 17:39:06 +00:00
Jim Meyering 2131b2e9d5 Protoize. 1996-01-19 16:05:23 +00:00
Jim Meyering 863c253425 (argdecode): Declare parameter const. 1996-01-17 17:50:08 +00:00
Jim Meyering 08d800d44e (advance): Protoize function. 1996-01-17 17:46:12 +00:00
Jim Meyering e23e3f656a Break some long lines.
Add const attribute to a few parameters.
1996-01-17 17:44:22 +00:00
Jim Meyering 4ad4b8aaec (integer_arg): Use xstrtol instead of open-coding this. 1996-01-17 17:41:00 +00:00
Jim Meyering 2a0d3143dd (visible): Change parameter type to unsigned int from unsigned char. 1996-01-17 17:20:41 +00:00
Jim Meyering 6e867c19c9 Protoize and __P-protect forward dcls. 1996-01-17 17:19:07 +00:00
Jim Meyering c78152220a Indent cpp directives. 1996-01-14 04:31:59 +00:00
Jim Meyering be2519d4dd . 1996-01-14 04:19:34 +00:00
Jim Meyering 9800c1597f Include config.h. 1996-01-14 04:18:48 +00:00
Jim Meyering 13751495a1 (print_element): Change type of argument from char
to int to avoid potential promotion problem.
1996-01-07 04:08:44 +00:00
Jim Meyering 1d2f218bff (print_esc_char): Change type of argument from char to int to avoid
potential promotion problem.
1996-01-07 04:06:41 +00:00
Jim Meyering 00b953713e Fix typo in __P use. 1996-01-07 04:04:48 +00:00
Jim Meyering 53398947a1 Protoize and __P-protect forward dcls. 1996-01-06 11:44:05 +00:00