1
0
mirror of git://git.sv.gnu.org/coreutils.git synced 2026-04-20 18:56:39 +02:00
Commit Graph

19672 Commits

Author SHA1 Message Date
Paul Eggert
82a15eefa3 (gl_CANON_HOST): Check for getaddrinfo. 2004-11-16 20:39:19 +00:00
Paul Eggert
4ec053b59d Include "strdup.h".
(canon_host): Use getaddrinfo if available, so that IPv6 works.
Use strdup instead of malloc/strcpy to duplicate strings.
2004-11-16 20:38:33 +00:00
Paul Eggert
5f2cb6ee45 doc patches inspired by Debian coreutils 5.2.1-2. 2004-11-16 20:31:21 +00:00
Paul Eggert
4aaf33c29e (General output formatting): -x doesn't have
an operand.
(Formatting the file names): Warn that even with -N unprintable
chars are still printed as '?' some times.
(rm invocation): Reword rm -d to note that it's sometimes useful
on non-directories.
(logname invocation, users invocation, who invocation):
The utmp and wtmp file names vary from system to system.
2004-11-16 20:29:58 +00:00
Paul Eggert
871422ab9d * getdate.y (tORDINAL): New token. 2004-11-16 08:18:49 +00:00
Paul Eggert
511f4b4165 * getdate.texi (General date syntax): "next" is 1, not 2. 2004-11-16 08:18:05 +00:00
Paul Eggert
37c8b2b848 (General date syntax): "next" is 1, not 2.
Document that "second" isn't allowed as an ordinal number.
2004-11-16 08:16:57 +00:00
Paul Eggert
1a126a5899 (tORDINAL): New token.
(day, relunit): Allow it for relative times.
(relative_time_table): Use tORDINAL for ordinals.
2004-11-16 08:16:10 +00:00
Paul Eggert
13ebfcf5c2 Support for human_space_before_unit. 2004-11-16 07:54:07 +00:00
Paul Eggert
7ce1f197f3 (human_readable): Support human_space_before_unit. 2004-11-16 07:53:08 +00:00
Paul Eggert
c49c8d6fee (LONGEST_HUMAN_READABLE): Add 1 for space before unit.
(human_space_before_unit): New constant.
2004-11-16 07:51:59 +00:00
Paul Eggert
bf45c74d3c New dd operand "status=noxfer". Change diagnostic wording slightly. 2004-11-16 07:50:07 +00:00
Paul Eggert
1855111a62 * coreutils.texi (dd invocation): Reword the new dd message. 2004-11-16 07:49:15 +00:00
Paul Eggert
ae5c7e83c6 (dd invocation): Reword the new dd message. 2004-11-16 07:48:36 +00:00
Paul Eggert
0c3a6880f4 (@Tests): Use status=noxfer to avoid
problems with regression testing.
2004-11-16 07:46:58 +00:00
Paul Eggert
586b8823f9 (C_ASCII, C_EBCDIC, C_IBM, C_BLOCK, C_UNBLOCK,
C_LCASE, C_UCASE, C_SWAB, C_NOERROR, C_NOTRUNC, C_SYNC, C_TWOBUFS,
C_NOCREAT, C_EXCL, C_FDATASYNC, C_FSYNC): Now constants, not
macros.
(STATUS_NOXFER, statuses): New constants.
(usage, print_stats, scanargs): Add support for status=noxfer.
(usage): Update status output to match new behavior.
(print_stats): Always output complete byte count.
Put space between numbers and units, as SI requires.
Use ngettext so that i18n can use plurals for "byte" and "second".
Don't multiply by 1e-9 (inexact); divide by 1e9 (which is exact).
(iflag_error_msgid, oflag_error_msgid): Remove; replace uses by
the string.
2004-11-16 07:46:08 +00:00
Paul Eggert
537acced26 New dd operand "status=noxfer". 2004-11-16 07:45:15 +00:00
Paul Eggert
f90de3d443 dd now outputs total bytes, seconds, and bytes per second. 2004-11-15 06:50:44 +00:00
Paul Eggert
9213ced1a7 (dd invocation): dd now outputs total bytes,
seconds, and bytes per second.
2004-11-15 06:50:23 +00:00
Paul Eggert
7d8f8967f3 Include "human.h".
(w_bytes, start_time): New vars.
(usage): Document new I/O statistics output
(print_stats): Output new I/O statistics.
(cleanup): Do statistics after closing stdin and stdout, so that
the times are more accurate.
(write_output, dd_copy): Count output bytes.
(main): Get initial value of clock.
2004-11-15 06:49:59 +00:00
Paul Eggert
c7169d726f (dd_LDADD): Add $(LIB_CLOCK_GETTIME). 2004-11-15 06:49:36 +00:00
Paul Eggert
07e17aad2a dd now outputs total bytes, seconds, and bytes per second. 2004-11-15 06:49:08 +00:00
Jim Meyering
e9dfe6f0d5 *** empty log message *** 2004-11-14 13:55:17 +00:00
Jim Meyering
484dcf4133 *** empty log message *** 2004-11-14 11:08:22 +00:00
Jim Meyering
99c79f5adc *** empty log message *** 2004-11-14 09:58:19 +00:00
Jim Meyering
2317cc3fe3 Backslash-escape `-'s in email addresses, so that they are
rendered properly in UTF-locales.

(escape_hyphens): New function.
(main): Call it on email addresses.
2004-11-14 09:48:05 +00:00
Jim Meyering
81720d306e (usage): Put the description of `[-n] STRING'
on two lines, one for `-n STRING' and one for `STRING' so that
help2man properly escapes the `-'.  Otherwise, the hyphen is
rendered inappropriately in UTF-8 locales.
2004-11-14 08:56:53 +00:00
Jim Meyering
cf53828748 restore file, now that closeout needs the function again 2004-11-14 08:49:46 +00:00
Jim Meyering
16fb1d072c *** empty log message *** 2004-11-14 08:36:43 +00:00
Jim Meyering
c5b7dbc58e (zaptemp): Mark new diagnostic for translation. 2004-11-14 08:36:30 +00:00
Jim Meyering
1dc343bb3a *** empty log message *** 2004-11-14 00:40:03 +00:00
Jim Meyering
efc10a4914 Do require gl_FUNC_FPENDING. 2004-11-14 00:34:04 +00:00
Jim Meyering
17b50219bd . 2004-11-14 00:33:27 +00:00
Jim Meyering
21bf149e86 . 2004-11-14 00:32:50 +00:00
Jim Meyering
d4ad5906ca . 2004-11-14 00:29:36 +00:00
Jim Meyering
fa83bf0b37 . 2004-11-14 00:20:33 +00:00
Jim Meyering
f094ac4413 (close_stdout): Don't fail just because stdout was
closed initially, since some programs don't write to stdout in the
normal course of operation (other than --version and --help), and
we don't want this function to make e.g. `cp 1 2 >&-' fail.
But do fail if it was closed and someone has tried to write to it.
E.g., printf 'foo' >&-
2004-11-14 00:20:01 +00:00
Jim Meyering
d417dd764f (libfetish_a_SOURCES): Add __fpending.h. 2004-11-14 00:19:28 +00:00
Jim Meyering
9406daed19 Restore these files. They're useful after all. 2004-11-14 00:19:01 +00:00
Jim Meyering
8ce39412c3 New file. Test today's closeout.c change. 2004-11-14 00:17:24 +00:00
Jim Meyering
545e8add4d (TESTS): Add close-stdout. 2004-11-14 00:17:10 +00:00
Paul Eggert
7e8e1db3d3 * src/sort.c (zaptemp): Warn if a temporary file is not removed. 2004-11-13 04:49:14 +00:00
Paul Eggert
af6bd870f4 (zaptemp): Warn if a temporary file is not removed.
Prune unnecessary accesses to volatile locations, and take some
code out of the critical section that didn't need to be in it.
2004-11-13 04:45:58 +00:00
Paul Eggert
1b2e96f830 Make the newly-introduced critical section a bit smaller. 2004-11-13 01:02:48 +00:00
Paul Eggert
fc19c2ddad * src/sort.c: Avoid O(N**2) behavior when there are many temporary files.
Fix a race condition.
2004-11-13 00:53:23 +00:00
Paul Eggert
54e862641b Document today's changes to "sort". 2004-11-13 00:52:32 +00:00
Paul Eggert
8aed6ea305 Avoid O(N**2) behavior when there are many temporary files.
(temptail): New variable, so that we can easily append to list.
(create_temp_file): Create new files at end of list, so that
searching the list has O(N**NMERGE) behavior instead of O(N**2).
(zaptemp): Update temptail if needed.
(mergefps, merge): Accept new arg that counts temp files, and keep it
up to date as we create and remove temporaries.  This is for
efficiency, so that we don't call zaptemp so often.
All callers changed.
(sort): Don't create array in reverse order, since the list of
temporaries is now in the correct order.

(zaptemp): Protect against race condition: if 'sort' is
interrupted in the middle of zaptemp, it might unlink the
temporary file twice, and the second time this happens the file
might already have been created by some other process.

(create_temp_file): Use offsetof for clarity.
(die): Move it up earlier, to clean up the code a bit.
2004-11-13 00:50:56 +00:00
Paul Eggert
0174a06214 Move "Version" to top. 2004-11-12 19:37:10 +00:00
Paul Eggert
222bd8934b Support longer page numbers in "pr", and allow most file names starting
with "+".
2004-11-12 19:36:51 +00:00
Paul Eggert
80877e6a38 Document recent changes to "pr". 2004-11-12 19:36:18 +00:00