Jim Meyering [Sat, 29 May 2004 21:12:30 +0000 (21:12 +0000)]
.
Jim Meyering [Sat, 29 May 2004 20:46:43 +0000 (20:46 +0000)]
Fix typo: use ls -ldo, not ls -ldg. Patch from Albert Chin.
Jim Meyering [Sat, 29 May 2004 16:53:50 +0000 (16:53 +0000)]
*** empty log message ***
Jim Meyering [Sat, 29 May 2004 16:53:45 +0000 (16:53 +0000)]
(AC_FUNC_CALLOC, _AC_FUNC_CALLOC_IF): New file/macros.
Jim Meyering [Sat, 29 May 2004 16:47:13 +0000 (16:47 +0000)]
New file.
Jim Meyering [Sat, 29 May 2004 11:33:15 +0000 (11:33 +0000)]
(text_buffer_maxend): Remove declarations unused variable.
Jim Meyering [Fri, 28 May 2004 22:31:38 +0000 (22:31 +0000)]
*** empty log message ***
Jim Meyering [Fri, 28 May 2004 22:31:26 +0000 (22:31 +0000)]
(push_dir): Merge declaration and adjacent assignment into a single statement.
Jim Meyering [Fri, 28 May 2004 22:30:40 +0000 (22:30 +0000)]
tweak a comment
Jim Meyering [Fri, 28 May 2004 21:39:59 +0000 (21:39 +0000)]
*** empty log message ***
Jim Meyering [Fri, 28 May 2004 21:39:55 +0000 (21:39 +0000)]
(AD_mark_helper): Eliminate unnecessary comparison.
Jim Meyering [Fri, 28 May 2004 21:27:16 +0000 (21:27 +0000)]
*** empty log message ***
Jim Meyering [Fri, 28 May 2004 21:04:15 +0000 (21:04 +0000)]
*** empty log message ***
Jim Meyering [Fri, 28 May 2004 21:01:53 +0000 (21:01 +0000)]
*** empty log message ***
Jim Meyering [Sat, 22 May 2004 16:30:11 +0000 (16:30 +0000)]
*** empty log message ***
Jim Meyering [Sat, 22 May 2004 16:29:20 +0000 (16:29 +0000)]
(rm): Use free rather than XFREE.
(remove_dir): Use xmalloc, not XMALLOC.
(ds_init): Likewise.
Jim Meyering [Fri, 21 May 2004 14:32:22 +0000 (14:32 +0000)]
*** empty log message ***
Jim Meyering [Fri, 21 May 2004 14:32:20 +0000 (14:32 +0000)]
(TESTS): Add inaccessible.
Jim Meyering [Fri, 21 May 2004 14:28:45 +0000 (14:28 +0000)]
*** empty log message ***
Jim Meyering [Fri, 21 May 2004 13:59:31 +0000 (13:59 +0000)]
# Ensure that rm works even when run from a directory
# for which the user has no access at all.
Jim Meyering [Fri, 21 May 2004 07:50:53 +0000 (07:50 +0000)]
*** empty log message ***
Jim Meyering [Fri, 21 May 2004 07:50:27 +0000 (07:50 +0000)]
update from gnulib
Jim Meyering [Fri, 21 May 2004 07:49:01 +0000 (07:49 +0000)]
*** empty log message ***
Jim Meyering [Fri, 21 May 2004 07:48:44 +0000 (07:48 +0000)]
update from gnulib
Jim Meyering [Fri, 21 May 2004 07:48:32 +0000 (07:48 +0000)]
*** empty log message ***
Jim Meyering [Fri, 21 May 2004 07:45:45 +0000 (07:45 +0000)]
update from gnulib
Jim Meyering [Fri, 21 May 2004 07:44:35 +0000 (07:44 +0000)]
update from gnulib
Jim Meyering [Fri, 21 May 2004 06:41:51 +0000 (06:41 +0000)]
update from gnulib, again
Jim Meyering [Fri, 21 May 2004 06:40:36 +0000 (06:40 +0000)]
*** empty log message ***
Jim Meyering [Fri, 21 May 2004 06:40:31 +0000 (06:40 +0000)]
Update from gnulib (fix reversed test).
Jim Meyering [Thu, 20 May 2004 11:39:58 +0000 (11:39 +0000)]
.
Jim Meyering [Thu, 20 May 2004 11:39:54 +0000 (11:39 +0000)]
Update from gnulib.
Jim Meyering [Thu, 20 May 2004 11:37:11 +0000 (11:37 +0000)]
*** empty log message ***
Jim Meyering [Thu, 20 May 2004 11:37:07 +0000 (11:37 +0000)]
(sc_unmarked_diagnostics): Now that the unmarked
diagnostics in shred.c have been fixed, don't exempt shred.c from
this check.
Jim Meyering [Thu, 20 May 2004 11:35:47 +0000 (11:35 +0000)]
*** empty log message ***
Jim Meyering [Thu, 20 May 2004 11:35:40 +0000 (11:35 +0000)]
Use translatable diagnostics, e.g.
change "%s: remove" to _("%s: failed to remove") and
change "%s: close" to _("%s: failed to close").
Jim Meyering [Thu, 20 May 2004 06:49:55 +0000 (06:49 +0000)]
*** empty log message ***
Jim Meyering [Thu, 20 May 2004 06:49:52 +0000 (06:49 +0000)]
Update from gnulib.
Jim Meyering [Tue, 18 May 2004 15:28:38 +0000 (15:28 +0000)]
*** empty log message ***
Jim Meyering [Tue, 18 May 2004 15:28:27 +0000 (15:28 +0000)]
(names): Bring back lower-case letters, "_", and
".". But continue to omit +, =, %, @, #, as they're either
shell metacharacters (for some shells) or are not in some
character sets, or (in the case of '%') must be a
metacharacter somewhere.
Jim Meyering [Mon, 17 May 2004 13:39:06 +0000 (13:39 +0000)]
*** empty log message ***
Jim Meyering [Mon, 17 May 2004 13:21:40 +0000 (13:21 +0000)]
.
Jim Meyering [Mon, 17 May 2004 13:20:25 +0000 (13:20 +0000)]
Sync with gnulib.
Jim Meyering [Mon, 17 May 2004 13:18:34 +0000 (13:18 +0000)]
Sync with gnulib.
Jim Meyering [Mon, 17 May 2004 13:17:45 +0000 (13:17 +0000)]
Sync with gnulib.
Jim Meyering [Mon, 17 May 2004 13:16:53 +0000 (13:16 +0000)]
(cut_fields): Adjust to new signature of getndelim2.
Jim Meyering [Mon, 17 May 2004 12:34:36 +0000 (12:34 +0000)]
(incname): Decrement `len' only once per loop iteration.
Jim Meyering [Mon, 17 May 2004 12:29:37 +0000 (12:29 +0000)]
*** empty log message ***
Jim Meyering [Mon, 17 May 2004 12:16:16 +0000 (12:16 +0000)]
*** empty log message ***
Jim Meyering [Mon, 17 May 2004 12:15:45 +0000 (12:15 +0000)]
*** empty log message ***
Jim Meyering [Mon, 17 May 2004 12:11:54 +0000 (12:11 +0000)]
.
Jim Meyering [Mon, 17 May 2004 12:11:19 +0000 (12:11 +0000)]
.
Jim Meyering [Mon, 17 May 2004 12:10:55 +0000 (12:10 +0000)]
*** empty log message ***
Jim Meyering [Mon, 17 May 2004 12:10:43 +0000 (12:10 +0000)]
Use -h where necessary to retain semantics.
Jim Meyering [Mon, 17 May 2004 12:08:24 +0000 (12:08 +0000)]
*** empty log message ***
Jim Meyering [Mon, 17 May 2004 12:08:09 +0000 (12:08 +0000)]
chgrp and chown now dereference symlinks by default, per POSIX.
(usage): Update to reflect this.
Jim Meyering [Mon, 17 May 2004 12:07:48 +0000 (12:07 +0000)]
(chopt_init): Affect each symlink referent by default.
Jim Meyering [Mon, 17 May 2004 12:07:30 +0000 (12:07 +0000)]
*** empty log message ***
Jim Meyering [Mon, 17 May 2004 12:07:25 +0000 (12:07 +0000)]
chgrp and chown now dereference symlinks by default, per POSIX.
(chgrp invocation, chown invocation): Document it.
Jim Meyering [Sun, 16 May 2004 21:39:35 +0000 (21:39 +0000)]
chown --dereference did nothing when the owner/group of a
symlink matched the desired owner/group. Reported by David Malone.
Also reported in 1999 as http://bugs.debian.org/39642.
(change_file_owner): When --dereference has
been specified, and when processing a symlink, stat it to get the
owner and group of the referent.
Jim Meyering [Sun, 16 May 2004 19:32:37 +0000 (19:32 +0000)]
*** empty log message ***
Jim Meyering [Sun, 16 May 2004 19:32:30 +0000 (19:32 +0000)]
In shred, check for errors from fdatasync more carefully. If
fdatasync fails with errno==EINVAL, it means this implementation
does not support synchronized I/O for this file. Do not report
this as an error, as (for example) AIX 5.2 fdatasync reports it
for raw disk devices. Problem reported by Albert Chin in
<http://mail.gnu.org/archive/html/bug-gnu-utils/2004-05/msg00028.html>.
Check for write errors, though: the old code ignored them.
Improve error checking in a few other cases, too (e.g., close of a
directory).
Also, change several 'int' values to 'bool', so that the error
checking is a bit clearer. Similarly, change unsigned values
to size_t where appropriate.
* src/shred.c: Include "dirname.h".
(datasync) [!HAVE_FDATASYNC]: Remove.
(dosync): New function.
(dopass): Use it. Return 1 on write error, -1 on other error.
All callers changed. Report write error if dosync does.
(do_wipefd, wipefd, wipename, wipefile): Return bool (true/false),
not int (0/-1). All callers changed. Return false if there's a
write error.
(incname): Return bool (true/false), not int (0/1). Accept
size_t length, not unsigned. All callers changed. Do not
bother checking for non-digits; it can't happen. Replace
recursion with iteration.
(wipename): Use dir_name, base_name, etc. instead of assuming
Unix file names. Use size_t for length, not unsigned.
Report error if unlink or close fails.
(wipename, main): Use bool for booleans.
(names): Use only digits and uppercase letters, for greater
portability.
Jim Meyering [Sun, 16 May 2004 14:18:50 +0000 (14:18 +0000)]
*** empty log message ***
Jim Meyering [Sun, 16 May 2004 14:17:53 +0000 (14:17 +0000)]
*** empty log message ***
Jim Meyering [Sun, 16 May 2004 14:10:17 +0000 (14:10 +0000)]
(TESTS): Add deref.
Jim Meyering [Sun, 16 May 2004 14:10:10 +0000 (14:10 +0000)]
New test for the yesterday's change.
Jim Meyering [Sat, 15 May 2004 18:27:38 +0000 (18:27 +0000)]
*** empty log message ***
Jim Meyering [Sat, 15 May 2004 14:59:15 +0000 (14:59 +0000)]
.
Jim Meyering [Fri, 14 May 2004 15:47:53 +0000 (15:47 +0000)]
(AD_pop_and_chdir): Eliminate an unnecessary call to AC_stack_top.
Jim Meyering [Fri, 14 May 2004 09:16:23 +0000 (09:16 +0000)]
.
Jim Meyering [Fri, 14 May 2004 07:34:16 +0000 (07:34 +0000)]
*** empty log message ***
Jim Meyering [Fri, 14 May 2004 07:34:09 +0000 (07:34 +0000)]
Improve performance of `sort -m' on large files, at the cost of
making some contrived examples unsafe. POSIX allows this
optimization. Performance problem reported by Jonathan Baker in
<http://mail.gnu.org/archive/html/bug-coreutils/2004-05/msg00071.html>.
(first_same_file): Do not treat input pipes
differently from other files.
Jim Meyering [Fri, 14 May 2004 07:33:48 +0000 (07:33 +0000)]
Document that "sort -m -o F" might write F before reading all the input.
Jim Meyering [Fri, 14 May 2004 07:33:23 +0000 (07:33 +0000)]
*** empty log message ***
Jim Meyering [Fri, 14 May 2004 07:32:56 +0000 (07:32 +0000)]
(sort invocation): Document that "sort -m -o F"
might write F before reading all the input.
Jim Meyering [Fri, 14 May 2004 07:29:41 +0000 (07:29 +0000)]
*** empty log message ***
Jim Meyering [Fri, 14 May 2004 07:29:04 +0000 (07:29 +0000)]
*** empty log message ***
Jim Meyering [Fri, 14 May 2004 07:28:39 +0000 (07:28 +0000)]
Fix typo: s/supercede/supersede/.
Jim Meyering [Thu, 13 May 2004 07:27:25 +0000 (07:27 +0000)]
*** empty log message ***
Jim Meyering [Thu, 13 May 2004 07:27:10 +0000 (07:27 +0000)]
(unquote, make_printable_str): Use e.g. '\a' rather than '\007',
for portability to EBCDIC hosts.
Jim Meyering [Thu, 13 May 2004 07:26:46 +0000 (07:26 +0000)]
(print_esc_char): Use e.g. '\a' rather than '\007',
for portability to EBCDIC hosts.
Jim Meyering [Thu, 13 May 2004 07:26:14 +0000 (07:26 +0000)]
(print_ascii, dump_strings): Use e.g. '\a' rather than
'\007', for portability to EBCDIC hosts.
Jim Meyering [Thu, 13 May 2004 07:05:05 +0000 (07:05 +0000)]
*** empty log message ***
Jim Meyering [Thu, 13 May 2004 07:04:58 +0000 (07:04 +0000)]
Don't assume that "make -C" works; Solaris "make" doesn't have -C.
* src/Makefile.am (all_programs.list): New rule, copied from
man/Makefile.am and tests/Makefile.am, except that we use the
system tr rather than ./tr and we don't use tr -s.
* tests/Makefile.am (all_programs): Use it.
* man/Makefile.am (all_programs): Likewise. Renamed from programs,
for consistency. All uses changed.
Jim Meyering [Thu, 13 May 2004 07:03:52 +0000 (07:03 +0000)]
Don't assume that "make -C" works; Solaris "make" doesn't have -C.
* src/Makefile.am (all_programs.list): New rule, copied from
man/Makefile.am and tests/Makefile.am, except that we use the
system tr rather than ./tr and we don't use tr -s.
* tests/Makefile.am (all_programs): Use it.
Jim Meyering [Thu, 13 May 2004 07:03:00 +0000 (07:03 +0000)]
Don't assume that "make -C" works; Solaris "make" doesn't have -C.
(all_programs.list): New rule, copied from
man/Makefile.am and tests/Makefile.am, except that we use the
system tr rather than ./tr and we don't use tr -s.
Jim Meyering [Wed, 12 May 2004 09:35:19 +0000 (09:35 +0000)]
*** empty log message ***
Jim Meyering [Wed, 12 May 2004 09:35:06 +0000 (09:35 +0000)]
(AD_pop_and_chdir): Move lstat-`.' into if-block
where the result is used. This avoids one unnecessary lstat call
per command line argument.
Jim Meyering [Tue, 11 May 2004 19:41:37 +0000 (19:41 +0000)]
*** empty log message ***
Jim Meyering [Tue, 11 May 2004 19:41:33 +0000 (19:41 +0000)]
(TESTS): Add unread3.
Jim Meyering [Tue, 11 May 2004 19:41:23 +0000 (19:41 +0000)]
New test, for the above fix and today's lib/save-cwd.c improvement.
Jim Meyering [Tue, 11 May 2004 18:34:56 +0000 (18:34 +0000)]
*** empty log message ***
Jim Meyering [Tue, 11 May 2004 18:34:38 +0000 (18:34 +0000)]
(save_cwd): If opening `.' read-only fails, try write-only.
Jim Meyering [Tue, 11 May 2004 18:25:32 +0000 (18:25 +0000)]
*** empty log message ***
Jim Meyering [Tue, 11 May 2004 16:50:25 +0000 (16:50 +0000)]
*** empty log message ***
Jim Meyering [Tue, 11 May 2004 16:48:42 +0000 (16:48 +0000)]
*** empty log message ***
Jim Meyering [Tue, 11 May 2004 16:42:17 +0000 (16:42 +0000)]
(save_cwd) [HAVE_FCHDIR]: Don't fail just
because opening `.' failed. Resort to using xgetcwd.
Jim Meyering [Tue, 11 May 2004 16:14:22 +0000 (16:14 +0000)]
*** empty log message ***
Jim Meyering [Tue, 11 May 2004 16:14:11 +0000 (16:14 +0000)]
Don't include "save-cwd.h". It's no longer used.
Jim Meyering [Mon, 10 May 2004 18:15:41 +0000 (18:15 +0000)]
.