Jim Meyering [Tue, 12 Feb 2002 15:46:34 +0000 (15:46 +0000)]
(DEFAULT_SUFFIX_LENGTH): Define constant.
(suffix_length): Use it here.
(usage): Use it here.
Jim Meyering [Tue, 12 Feb 2002 15:44:16 +0000 (15:44 +0000)]
Include "dirname.h".
(outbase): Now a global var.
(outfile_end): Remove.
(suffix_length): New var.
(shortopts, longopts, main): Add -a or --suffix-length.
(next_file_name): Implement -a. Do not extend the suffix length.
Check for file names that are too long.
(main): Move outfile initialization to next_file_name.
(shortopts): Remove -v (a typo).
Jim Meyering [Tue, 12 Feb 2002 07:40:54 +0000 (07:40 +0000)]
*** empty log message ***
Jim Meyering [Tue, 12 Feb 2002 07:40:39 +0000 (07:40 +0000)]
*** empty log message ***
Jim Meyering [Tue, 12 Feb 2002 07:40:24 +0000 (07:40 +0000)]
(main): Output warnings only if OBSOLETE_OPTION_WARNINGS.
Jim Meyering [Mon, 11 Feb 2002 23:27:05 +0000 (23:27 +0000)]
.
Jim Meyering [Mon, 11 Feb 2002 23:26:20 +0000 (23:26 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 23:25:34 +0000 (23:25 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal
for support of obsolete "-DIGITS" option syntax in nice, and
which prohibits options with optional arguments like date's
-I option.
Document this.
Jim Meyering [Mon, 11 Feb 2002 23:23:48 +0000 (23:23 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 23:23:42 +0000 (23:23 +0000)]
(main): Conform to POSIX 1003.1-2001 if
POSIX2_VERSION says to, otherwise warn of obsolete usage if
OBSOLETE_OPTION_WARNINGS is nonzero and if not POSIXLY_CORRECT.
Jim Meyering [Mon, 11 Feb 2002 22:58:59 +0000 (22:58 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal
for support of obsolete "-DIGITS" option syntax in nice, and
which prohibits options with optional arguments like date's
-I option.
(ISO_8601_OPTION): New enum value.
(long_options): Use it.
(short_options): New constant.
(usage): Document the change.
(main): Conform to POSIX 1003.1-2001 if
POSIX2_VERSION says to, otherwise warn of obsolete usage if
OBSOLETE_OPTION_WARNINGS is nonzero and if not POSIXLY_CORRECT.
Jim Meyering [Mon, 11 Feb 2002 21:45:02 +0000 (21:45 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 21:44:35 +0000 (21:44 +0000)]
(usage): Describe %F, %g, %G, %P, and %R.
Jim Meyering [Mon, 11 Feb 2002 15:11:05 +0000 (15:11 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
Jim Meyering [Mon, 11 Feb 2002 15:04:51 +0000 (15:04 +0000)]
.
Jim Meyering [Mon, 11 Feb 2002 14:35:02 +0000 (14:35 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 14:34:49 +0000 (14:34 +0000)]
Use `tail -n +2', rather than `tail +2'.
Jim Meyering [Mon, 11 Feb 2002 14:32:49 +0000 (14:32 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 14:32:22 +0000 (14:32 +0000)]
From Bruno Haible
(print_esc): Call print_unicode_char with exit_on_error = false.
Jim Meyering [Mon, 11 Feb 2002 14:29:31 +0000 (14:29 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 14:28:35 +0000 (14:28 +0000)]
2002-02-02 Paul Eggert <eggert@twinsun.com>
Bruno Haible <bruno@clisp.org>
* unicodeio.c (unicode_to_mb): New function, extracted from
print_unicode_char. Call failure callback instead of error.
(fwrite_success_callback): New function.
(exit_failure_callback): New function.
(fallback_failure_callback): New function.
(print_unicode_char): Call unicode_to_mb.
Jim Meyering [Mon, 11 Feb 2002 14:28:09 +0000 (14:28 +0000)]
2002-02-02 Paul Eggert <eggert@twinsun.com>
Bruno Haible <bruno@clisp.org>
* unicodeio.c (unicode_to_mb): New function, extracted from
print_unicode_char. Call failure callback instead of error.
(fwrite_success_callback): New function.
(exit_failure_callback): New function.
(fallback_failure_callback): New function.
(print_unicode_char): Call unicode_to_mb.
Jim Meyering [Mon, 11 Feb 2002 14:13:30 +0000 (14:13 +0000)]
.
Jim Meyering [Mon, 11 Feb 2002 11:00:55 +0000 (11:00 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 11:00:46 +0000 (11:00 +0000)]
(TESTS): Add head-pos.
Jim Meyering [Mon, 11 Feb 2002 11:00:10 +0000 (11:00 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 11:00:00 +0000 (11:00 +0000)]
(head_lines): If we have read too much data, try
to seek back to the position we would have gotten to had we
been reading one byte at a time. POSIX currently doesn't
require this, but it's easy to do and some software relies on it.
Jim Meyering [Mon, 11 Feb 2002 10:55:51 +0000 (10:55 +0000)]
New file/test for the change of 2002-02-08.
Jim Meyering [Mon, 11 Feb 2002 08:37:00 +0000 (08:37 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 08:35:10 +0000 (08:35 +0000)]
*** empty log message ***
Jim Meyering [Mon, 11 Feb 2002 08:34:47 +0000 (08:34 +0000)]
(unquote): Make comment a little clearer.
Jim Meyering [Sun, 10 Feb 2002 21:04:12 +0000 (21:04 +0000)]
*** empty log message ***
Jim Meyering [Sat, 2 Feb 2002 09:54:50 +0000 (09:54 +0000)]
*** empty log message ***
Jim Meyering [Sat, 2 Feb 2002 09:54:38 +0000 (09:54 +0000)]
(main): Prepend `warning: ' to the diagnostic, so it's
consistent with all of the other `... is obsolete...' diagnostics.
Jim Meyering [Sat, 2 Feb 2002 09:53:26 +0000 (09:53 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(usage): Document this.
(shortopts): New constant.
(main): Check for obsolete options.
Jim Meyering [Sat, 2 Feb 2002 09:47:57 +0000 (09:47 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(usage): Document this.
(shortopts): New constant.
(main): Check for obsolete options.
Jim Meyering [Sat, 2 Feb 2002 09:40:50 +0000 (09:40 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(usage): Document this.
(main): Check for obsolete options.
(shortopts): New constant.
(main): Use -1, not EOF, for getopt_long.
Jim Meyering [Sat, 2 Feb 2002 09:37:12 +0000 (09:37 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(main): Check for obsolete options.
(short_options): New constant.
Jim Meyering [Sat, 2 Feb 2002 09:35:52 +0000 (09:35 +0000)]
*** empty log message ***
Jim Meyering [Sat, 2 Feb 2002 09:35:43 +0000 (09:35 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(usage): Document it.
(main): Check for obsolete options.
(short_options): New constant.
(SEP_STRING_OPTION): New enum value.
(long_options): Use it.
Jim Meyering [Sat, 2 Feb 2002 09:31:09 +0000 (09:31 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(usage): Document it.
(main): Check for obsolete options.
(short_options): New constant.
New enum for long options.
Jim Meyering [Sat, 2 Feb 2002 08:10:04 +0000 (08:10 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(usage): Document it.
(main): Check for obsolete options.
(header_mode_option): New constant.
Jim Meyering [Sat, 2 Feb 2002 07:58:50 +0000 (07:58 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(main): Check for obsolete options.
(main): Fix bug: -- -N was treated as -N --.
Jim Meyering [Sat, 2 Feb 2002 07:54:49 +0000 (07:54 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(shortopts): New constant.
(main): Check for obsolete options.
Jim Meyering [Sat, 2 Feb 2002 00:06:50 +0000 (00:06 +0000)]
(OPTARG_POSIX, OBSOLETE_OPTION_WARNINGS): New macros.
Jim Meyering [Fri, 1 Feb 2002 23:47:28 +0000 (23:47 +0000)]
*** empty log message ***
Jim Meyering [Fri, 1 Feb 2002 23:43:46 +0000 (23:43 +0000)]
* src/shred.c: (VERBOSE_UPDATE): Update every 5 seconds, not every 10.
(wipename): Quote file names only when necessary.
(main): Copy quoted string into malloc'd storage so it doesn't
get clobbered when using -u and --verbose.
Minor clean-up.
* src/shred.c:
Use `NULL' rather than `(time_t *) 0'.
(dopass): Use STREQ in place of strcmp.
Add parentheses around use of nested ternary operator.
Jim Meyering [Fri, 1 Feb 2002 23:34:57 +0000 (23:34 +0000)]
(VERBOSE_UPDATE): Now counts seconds, not bytes.
(dopass): If verbose, output a line every VERBOSE_UPDATE seconds,
and suppress duplicate output lines. Output a percentage as well
as a count of bytes.
Also, fix comment/code typo regarding how many bytes have been
written; this typo was harmless before, but is no longer harmless with
the above change in effect.
Jim Meyering [Fri, 1 Feb 2002 23:30:23 +0000 (23:30 +0000)]
(rm): Add a comment.
Jim Meyering [Fri, 1 Feb 2002 16:31:55 +0000 (16:31 +0000)]
Add more support for POSIX 1003.1-2001, which requires removal for
support of obsolete "-N" option syntax in expand, head, fold,
split, tail, unexpand, uniq, and which prohibits options with
optional arguments in od and pr.
(parse_obsolescent_option, main): Likewise.
Jim Meyering [Fri, 1 Feb 2002 09:12:50 +0000 (09:12 +0000)]
(start_lines): Handle the case in which bytes_read is zero.
Jim Meyering [Mon, 28 Jan 2002 13:51:22 +0000 (13:51 +0000)]
*** empty log message ***
Jim Meyering [Mon, 28 Jan 2002 13:50:50 +0000 (13:50 +0000)]
(ac-check): Remove, now that we no longer have
to duplicate that information.
Jim Meyering [Mon, 28 Jan 2002 10:10:33 +0000 (10:10 +0000)]
*** empty log message ***
Jim Meyering [Mon, 28 Jan 2002 10:09:08 +0000 (10:09 +0000)]
*** empty log message ***
Jim Meyering [Mon, 28 Jan 2002 10:08:38 +0000 (10:08 +0000)]
*** empty log message ***
Jim Meyering [Mon, 28 Jan 2002 06:30:41 +0000 (06:30 +0000)]
*** empty log message ***
Jim Meyering [Sun, 27 Jan 2002 07:53:45 +0000 (07:53 +0000)]
*** empty log message ***
Jim Meyering [Sun, 27 Jan 2002 07:53:37 +0000 (07:53 +0000)]
tail -n +2 would perform an extra read after encountering EOF
(start_lines): Detect EOF, inform caller.
(tail_lines): Upon EOF in start_lines, return immediately.
Jim Meyering [Sat, 26 Jan 2002 22:04:00 +0000 (22:04 +0000)]
split a long line
Jim Meyering [Sat, 26 Jan 2002 19:03:43 +0000 (19:03 +0000)]
.
Jim Meyering [Sat, 26 Jan 2002 19:03:23 +0000 (19:03 +0000)]
(jm_MACROS): Require autoconf-2.52g.
Jim Meyering [Sat, 26 Jan 2002 09:56:05 +0000 (09:56 +0000)]
.
Jim Meyering [Sat, 26 Jan 2002 09:55:15 +0000 (09:55 +0000)]
*** empty log message ***
Jim Meyering [Sat, 26 Jan 2002 09:55:02 +0000 (09:55 +0000)]
(getdate$U.o): Depend on unlocked-io.h.
Jim Meyering [Thu, 24 Jan 2002 09:14:52 +0000 (09:14 +0000)]
*** empty log message ***
Jim Meyering [Thu, 24 Jan 2002 09:14:45 +0000 (09:14 +0000)]
(START-INFO-DIR-ENTRY): Remove a few entries
and clean up a few others based on suggestions from Bob Proulx.
Jim Meyering [Tue, 22 Jan 2002 18:16:06 +0000 (18:16 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 18:15:57 +0000 (18:15 +0000)]
(skip): Remove redundant check for overflow.
fseeko's seek argument is already known to be in range,
since it is less than the file size.
Jim Meyering [Tue, 22 Jan 2002 17:50:41 +0000 (17:50 +0000)]
(save_stdin): Report proper errno value after
fwrite failures. Do not bother to rewind the temp file, as
it'll be read backwards anyway.
Jim Meyering [Tue, 22 Jan 2002 12:00:00 +0000 (12:00 +0000)]
.
Jim Meyering [Tue, 22 Jan 2002 11:59:20 +0000 (11:59 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 11:59:11 +0000 (11:59 +0000)]
(Makefile): Don't depend on $(BUILT_SOURCES).
Otherwise, some versions of automake would omit the rule that makes
Makefile from Makefile.in.
Jim Meyering [Tue, 22 Jan 2002 11:58:36 +0000 (11:58 +0000)]
.
Jim Meyering [Tue, 22 Jan 2002 11:22:03 +0000 (11:22 +0000)]
header-check: fix it yet again
Jim Meyering [Tue, 22 Jan 2002 11:13:50 +0000 (11:13 +0000)]
(header-check): Add `&& :'.
Jim Meyering [Tue, 22 Jan 2002 11:12:00 +0000 (11:12 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 11:11:22 +0000 (11:11 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 11:03:33 +0000 (11:03 +0000)]
.
Jim Meyering [Tue, 22 Jan 2002 11:02:31 +0000 (11:02 +0000)]
update copyright year
Jim Meyering [Tue, 22 Jan 2002 10:51:53 +0000 (10:51 +0000)]
(swallow_file_in_memory): Work even if `open' returns 0.
Check for `close' error.
Jim Meyering [Tue, 22 Jan 2002 10:47:14 +0000 (10:47 +0000)]
remove the parens I just added to Paul's patch
Jim Meyering [Tue, 22 Jan 2002 10:46:05 +0000 (10:46 +0000)]
(EOVERFLOW, fseeko): New macros.
Jim Meyering [Tue, 22 Jan 2002 10:44:13 +0000 (10:44 +0000)]
(skip): Use fseeko rather than lseek.
(Also, check for overflow when converting uintmax_t to off_t.)
Jim Meyering [Tue, 22 Jan 2002 10:34:49 +0000 (10:34 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 10:34:43 +0000 (10:34 +0000)]
(jm_MACROS): Require AC_FUNC_FSEEKO.
Jim Meyering [Tue, 22 Jan 2002 09:53:13 +0000 (09:53 +0000)]
.
Jim Meyering [Tue, 22 Jan 2002 08:14:46 +0000 (08:14 +0000)]
.
Jim Meyering [Tue, 22 Jan 2002 08:13:00 +0000 (08:13 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 08:12:51 +0000 (08:12 +0000)]
Include xmemcoll.h, not memcoll.h.
Use xmemcoll instead of memcoll.
(die): Do not invoke cleanup; atexit does this now.
(main): Use atexit to invoke cleanup on exit.
Set xmemcoll_exit_failure to SORT_FAILURE.
Jim Meyering [Tue, 22 Jan 2002 08:11:04 +0000 (08:11 +0000)]
Include xmemcoll.h, not memcoll.h.
Use xmemcoll instead of memcoll.
Jim Meyering [Tue, 22 Jan 2002 08:04:03 +0000 (08:04 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 08:03:54 +0000 (08:03 +0000)]
(libfetish_a_SOURCES): Add them.
Jim Meyering [Tue, 22 Jan 2002 08:02:55 +0000 (08:02 +0000)]
*** empty log message ***
Jim Meyering [Tue, 22 Jan 2002 08:02:43 +0000 (08:02 +0000)]
(quotearg_n_style_mem): New function.
Jim Meyering [Tue, 22 Jan 2002 08:02:22 +0000 (08:02 +0000)]
(quotearg_buffer_restyled):
Fix bug with quoting buffers containing NUL when backslashing escapes.
This bug was exposed by the other changes in this patch.
(quotearg_n_options): New arg ARGSIZE.
All callers changed.
(quoting_options_from_style): New function.
(quotearg_n_style): Use it.
(quotearg_n_style_mem): New function.
Jim Meyering [Tue, 22 Jan 2002 07:56:44 +0000 (07:56 +0000)]
Include errno.h, and declare errno if not defined.
(memcoll): Set errno to zero if there is no error.
Jim Meyering [Mon, 21 Jan 2002 23:33:51 +0000 (23:33 +0000)]
*** empty log message ***
Jim Meyering [Mon, 21 Jan 2002 22:02:35 +0000 (22:02 +0000)]
*** empty log message ***
Jim Meyering [Mon, 21 Jan 2002 22:02:28 +0000 (22:02 +0000)]
(CMP_WITH_IGNORE): Don't assume that the difference
between two size_t values can be stored in an int; this doesn't
work, for example, on 64-bit Solaris.