Age | Commit message (Collapse) | Author |
|
Use quote() in diagnostics, rather than literal `' marks.
(main): Exit nonzero when unable to open an input file.
|
|
|
|
(IF_READDIR_NEEDS_REWINDDIR): Define.
[! HAVE_WORKING_READDIR] (remove_cwd_entries): If readdir has just
returned NULL and there has been at least one successful unlink or
rmdir call since the opendir or previous rewinddir, then call
rewinddir and reiterate the loop.
|
|
(readdir_ignoring_dotdirs): New function.
(is_empty_dir): Use it here.
(remove_cwd_entries): Use it here.
|
|
(dump_remainder): Move two declarations `down' into the scope
where they are used.
(xlseek): Return the resulting offset.
(file_lines): Rename parameter, file_length, to end_pos.
(pipe_lines): Don't coerce safe_read return value to `int'.
Adapt tests accordingly.
(pipe_bytes) [struct charbuffer] (nbytes): Change type from `int'
to `unsigned int'.
Change type of `total_bytes' from `int' to `size_t',
since the former wouldn't always be wide enough.
Don't coerce safe_read return value to `int',
and adapt tests accordingly.
Now that testing for a read error no longer involves
using `tmp', handle that case *after* freeing `tmp'.
(start_bytes): Clean up.
(tail_bytes): Now that `n_bytes' may be larger than
OFF_T_MAX, test for that condition and, if it's true, don't
use lseek optimizations.
(parse_options): Don't fail just because N_UNITS is larger than
the maximum size of a file -- tail may be applied to an input
stream (e.g., a pipe) with more data than that.
|
|
|
|
|
|
|
|
(main): Minor syntactic clean-up.
|
|
|
|
|
|
|
|
<http://mail.gnu.org/archive/html/bug-coreutils/2003-04/msg00070.html>.
* doc/coreutils.texi (printf invocation): It's \NNN in the format,
\0NNN in the %b operand.
* src/printf.c (usage): Likewise.
(print_esc): New arg OCTAL0 to specify whether \0NNN or \NNN
is desired. All uses changed. Behave like Bash printf if %b
operand uses \NNN where the initial N is not 0.
|
|
|
|
|
|
--body-numbering=STYLE (-b), or --footer-numbering=STYLE (-f)) or
FORMAT (--number-format=FORMAT (-n)) would not give a useful diagnostic.
(main): Fix those problems and remove literal quote marks
(e.g., "`%s'") from format string; instead use "%s" in each format
string and `quote (optarg)' as the corresponding argument.
Also, diagnose all invalid command line options before failing.
|
|
for textutils-2.0.17, that would make nl output extra newlines
in some cases.
|
|
|
|
|
|
|
|
|
|
|
|
Remove trailing blanks.
filter though cppi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
xrealloc, and xcalloc return values and of xrealloc's first argument.
|
|
|
|
|
|
|
|
|
|
(BUILT_SOURCES): Add fs.h, now that it's generated.
(EXTRA_DIST): Add extract-magic.
|
|
|
|
fs.h in a comment after the corresponding `case S_MAGIC_...:' statement.
|
|
|
|
|
|
|
|
|
|
that's all that is supported for now.
(main): Check for overflow in obsolescent line count option.
|
|
uintmax_t original) in remaining computations. From Paul Eggert.
|
|
This allows e.g., splitting into files of size 2GB and larger,
and running split --lines=N with N=2^31 or more.
But for --line-bytes=N, the restriction that N <= SIZE_MAX
remains (for now), due to the way it is implemented.
Include "inttostr.h".
(bytes_split, lines_split, line_bytes_split, main):
Use uintmax_t, not size_t, for file sizes.
(main): Give a better diagnostic for option arguments == 0.
Use umaxtostr to print file sizes.
|
|
|
|
|
|
|
|
|
|
|
|
|