Commit Graph
2161 Commits
Author SHA1 Message Date
Jim Meyering 6b32b53027 Use HAVE_STRUCT_STAT_ST_BLOCKS, not deprecated HAVE_ST_BLOCKS. 1999-11-05 09:55:24 +00:00
Jim Meyering 2d81adfab6 (SORTALLOC): New macro.
(sortalloc, mergealloc, LINEALLOC): Use it.
(sortalloc, mergealloc, linelength): Now const.
(sortalloc): Increase from 0.5 to 8 MB.
(mergealloc): Increase from 16 to 256 kB.
(LINEALLOC): Increase from 0.25 to 4 MB.
1999-11-05 07:59:40 +00:00
Jim Meyering cec217ed93 (begfield, limfield, findlines, keycompare, compare):
Do not consider newline to be part of a line when comparing lines
in `sort' and `comm'.  POSIX.2 requires that we consider newline,
but this is a bug in the spec and the bug will likely be fixed.
1999-11-04 23:11:34 +00:00
Jim Meyering 0b7aeab254 (compare_files):
Do not consider newline to be part of a line when comparing lines
in `sort' and `comm'.  POSIX.2 requires that we consider newline,
but this is a bug in the spec and the bug will likely be fixed.
1999-11-04 23:11:03 +00:00
Jim Meyering 1c04247f53 Fix so that `tail -fn 2 file' works again.
(anonymous enum) [LONG_FOLLOW_OPTION]: Define.
(long_options): Use LONG_FOLLOW_OPTION here, instead of 'f'.
(main): Remove the `::' after the `f' in getopt_long string.
Add `case LONG_FOLLOW_OPTION' after `case 'f':'.
Based on a patch from Tim Waugh.
1999-11-03 13:06:50 +00:00
Jim Meyering 23d439f22b (anonymous enum) [RETRY_OPTION]: Define.
[MAX_UNCHANGED_STATS_OPTION]: Likewise.
[MAX_CONSECUTIVE_SIZE_CHANGES_OPTION]: Likewise.
[PID_OPTION]: Likewise.
(long_options): Use *_OPTION instead of CHAR_MAX + N.
(main): Likewise.
1999-11-03 12:26:24 +00:00
Jim Meyering 670f9b2f8a (recheck): Don't refuse to tail a non-regular, non-pipe.
(tail_file): Likewise.
1999-11-03 12:13:39 +00:00
Jim Meyering 84e957d300 (usage): Warn about mixing use of `-r' with FIFOs and
other special files like /dev/zero.
1999-11-01 16:00:40 +00:00
Jim Meyering 362c45be17 Convert --backup to take an optional argument.
Deprecate --version-control (-V) in comments.
(usage): Remove mention of --version-control.
(main): Make -V warn then fall through into --backup case.
[--backup case]: Handle optional arg.
1999-10-31 10:42:12 +00:00
Jim Meyering 60b24ab5af tweak usage 1999-10-31 10:36:54 +00:00
Jim Meyering 063d10ae6c (usage): Tweak --backup description 1999-10-30 07:04:01 +00:00
Jim Meyering d437084b93 Convert --backup to take an optional argument.
Deprecate --version-control (-V) in comments.
(usage): Remove mention of --version-control.
(main): Make -V warn then fall through into --backup case.
[--backup case]: Handle optional arg.
1999-10-30 06:30:56 +00:00
Jim Meyering 9ddb95e93c (do_copy): Constify `dest', and cast-away the new
const in assignment to new_dest.
1999-10-24 21:28:37 +00:00
Jim Meyering e3bd3c1c39 add missing program_name arg to match new usage %s 1999-10-24 21:26:51 +00:00
Jim Meyering 6d1aa48746 label use of -V/--versin-control as a warning 1999-10-23 15:32:01 +00:00
Jim Meyering a579a9f85b (full_write): Remove unused decl.
(open_maybe_create): Remove.
(touch): Don't record whether the file was created; this isn't
possible to do reliably and portably without race conditions.
If the file was created and if amtime_now is nonzero, this
change means we'll have to do another utime system call, but
that's no more harmful than the previous version of this code.
1999-10-23 11:46:03 +00:00
Jim Meyering 77def80003 Convert --backup to take an optional argument.
Deprecate --version-control (-V) in comments.
(usage): Remove mention of --version-control.
(main): Make -V warn then fall through into --backup case.
[--backup case]: Handle optional arg.
1999-10-17 21:31:45 +00:00
Jim Meyering 8bbc2e2937 change a message and add usage(1) to another. 1999-10-17 16:26:30 +00:00
Jim Meyering f893b3807d Accept new option: --target-directory=DIR
(TARGET_DIRECTORY_OPTION): Define.
(SPARSE_OPTION): Define.
(usage): Describe it.
(do_copy): Change meanings/names of first two parameters: use `n_files'
in place of `argc - optind', and `file' instead of `argv + optind'.
Add parameter, target_directory.
(main): Pass new arg, target_directory.
1999-10-17 10:01:30 +00:00
Jim Meyering a374a307c5 don't compute isdir() of -- or an option string 1999-10-17 07:39:20 +00:00
Jim Meyering b221905959 remove last `,' in enum 1999-10-17 07:25:34 +00:00
Jim Meyering 34306581ac Convert --backup to take an optional argument.
Deprecate --version-control (-V) in comments.
(usage): Remove mention of --version-control.
(main): Make -V warn then fall through into --backup case.
[--backup case]: Handle optional arg.
1999-10-16 14:48:16 +00:00
Jim Meyering 2de1a014ef Accept new option: --target-directory=DIR
(TARGET_DIRECTORY_OPTION): Define.
(usage): Describe it.
(main): Implement it.
Make code clearer:  use new variable `n_files' in place of
`argc - optind'.  Use `file' instead of `argv + optind'.
1999-10-09 13:22:08 +00:00
Jim Meyering 17754acc90 (__attribute__): Wrap with #ifndef __attribute__. 1999-10-04 06:04:19 +00:00
Jim Meyering 0226382b34 (__attribute__): Define to empty if GCC claims to
be before 2.8; this is needed for OPENStep 4.2 cc.  Also,
define to empty if strict ANSI.
1999-10-04 06:02:41 +00:00
Jim Meyering 84928ec02d (TARGET_DIRECTORY_OPTION): Define.
(usage): Describe it.
(main): Implement it.
Remove unused variable, stdin_tty.
Make code clearer:  use new variable `n_files' in place of
`argc - optind'.  Use `file' instead of `argv + optind'.
1999-10-03 16:59:07 +00:00
Jim Meyering ea0df9b67d Do s/#ifdef HAVE_/#if HAVE_/ -- solely for aesthetics.
Do the same for other config.h macros like CLOSEDIR_VOID and MAJOR_*.
1999-09-28 16:22:54 +00:00
Jim Meyering 98ba27811d Do s/#ifdef HAVE_/#if HAVE_/ -- solely for aesthetics. 1999-09-28 16:22:38 +00:00
Jim Meyering 1648386aa0 (siginfo_handler): Mark parameter with ATTRIBUTE_UNUSED.
Change lots of count and index variables to be of unsigned type.
(dd_copy): Add new unsigned variable, n_bytes_read, in place of
many uses of `nread'.
1999-09-19 16:23:17 +00:00
Jim Meyering 96949ef7f5 (__attribute__): Define.
(ATTRIBUTE_NORETURN): Remove #else clause.
(ATTRIBUTE_UNUSED): Define.
1999-09-19 16:21:26 +00:00
Jim Meyering 67aaf0afa6 (usage): Remove misleading sentence in --help output.
From Karl Heuer.
1999-09-09 19:56:10 +00:00
Jim Meyering fc02691130 Remove declaration of xstrdup. 1999-09-08 08:39:49 +00:00
Jim Meyering 85e0053136 Remove xstrdup declaration. 1999-09-02 21:34:04 +00:00
Jim Meyering b10b8369dd Remove xstrdup declaration. 1999-09-02 21:33:23 +00:00
Jim Meyering 1aab3474a1 Remove xstrdup declaration. 1999-09-02 21:33:00 +00:00
Jim Meyering d1b4719534 Remove xstrdup declaration. 1999-09-02 21:31:19 +00:00
Jim Meyering 967bd9f5f0 Remove declaration of xstrdup. 1999-09-01 13:28:21 +00:00
Jim Meyering 8a29209450 Add .rpm, .png, and .fli.
From Andres Soolo.
1999-08-31 20:46:18 +00:00
Jim Meyering 038e5f009e (longopts): Restore accidentally-removed entry for `--portability' long option. 1999-08-30 14:43:52 +00:00
Jim Meyering 4ab0a2a4c6 (usage): Correct --help message. 1999-08-30 14:41:05 +00:00
Jim Meyering 4b20f454fe split a long line. 1999-08-30 14:39:05 +00:00
Jim Meyering 33bebae5ae (usage): Correct --help message. 1999-08-30 14:38:00 +00:00
Jim Meyering ccff4ede2b (usage): Correct --help message. 1999-08-30 14:37:40 +00:00
Jim Meyering 6f48cb1924 (usage): Correct --help message. 1999-08-30 14:36:26 +00:00
Jim Meyering 98ecd5b300 (usage): Correct --help message. 1999-08-30 14:36:06 +00:00
Jim Meyering 57e5f5a5b5 (usage): Correct --help message. 1999-08-30 14:35:45 +00:00
Jim Meyering 2a0b67dc3b (usage): Correct --help message. 1999-08-30 14:35:20 +00:00
Jim Meyering 75789c4643 (main): Call exit explicitly to avoid warning from gcc.
Include "xstrtol.h".
(isinteger): Remove function and prototype.
(main): Use xstrtol in place of atoi.  Remove associated FIXME comments.
1999-08-29 21:09:34 +00:00
Jim Meyering 678cbc835e (isinteger): Move definition to precede use. Remove prototype. 1999-08-29 20:49:07 +00:00
Jim Meyering de8d09d22d (main): Call exit explicitly to avoid warning from gcc. 1999-08-29 20:47:17 +00:00