1 2007-01-19 Dan Hipschman <dsh@linux.ucla.edu>
2 and Paul Eggert <eggert@cs.ucla.edu>
4 * src/sort.c (cleanup): Clear temphead at the end.
5 (exit_cleanup): New function.
6 (main): Don't invoke atexit until we're ready.
7 Invoke it with exit_cleanup, not with cleanup and close_stdout,
8 to avoid a race condition with cleanup and signal handling. More
9 details: http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/9508
11 2007-01-18 Jim Meyering <jim@meyering.net>
13 * src/c99-to-c89.diff: Adjust remove.c offsets.
15 2007-01-17 Jim Meyering <jim@meyering.net>
17 Make "rm --interactive=never ..." never prompt.
19 * src/remove.h (enum rm_interactive): New ternary type.
20 (struct rm_options) [interactive]: Use it, here -- rather than bool.
21 * src/remove.c (prompt): Reflect type change.
22 * src/mv.c (rm_option_init): Initialize to RMI_NEVER now.
23 * src/rm.c (main): Add a FIXME comment for '-d' option.
24 Adapt to type change of rm_options.interactive.
26 * tests/rm/i-never: New file. Test for the above fix.
27 * tests/rm/Makefile.am (TESTS): Add i-never.
29 2007-01-15 Jim Meyering <jim@meyering.net>
31 * bootstrap (gnulib_tool): When adding to .cvsignore and .gitignore,
32 emit foo.h, for each foo_.h. This yields one false-positive, fts.h,
33 but that's ok, since fts_.h will eventually be renamed.
35 * src/remove.c (remove_dir): Don't use errno in diagnostic.
36 Root-only test failure reported by Alex van Hout and Jon Grosshart in
37 <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/9415/focus=9415>.
39 * bootstrap.conf (avoided_gnulib_modules): Fix my typo:
40 s/--avoid=canonicalize-lgpl/--avoid=canonicalize-gpl/
42 2007-01-14 Bruno Haible <bruno@clisp.org>
44 Enable use of gnulib's new fchdir module.
45 * bootstrap.conf (avoided_gnulib_modules): Avoid canonicalize-lgpl,
46 since we use canonicalize.
47 (gnulib_modules): Add fchdir.
48 * m4/jm-macros.m4 (coreutils_MACROS): Remove fchdir-stub.
50 2007-01-13 Jim Meyering <jim@meyering.net>
52 * Transform all Makefile.am files so that when running "make check",
53 CU_TEST_NAME is set to the name of the test. This is so that when I
54 run valgrind-enabled (--log-file-qualifier=CU_TEST_NAME) "make check"
55 on the entire package it is more convenient to map a leak or error
56 found in a valgrind log file back to the offending test.
58 (echo tests/Makefile.am.in; find tests -name Makefile.am) \
59 |xargs perl -pi -e '/^(\s*)PATH=...VG_PATH_PREFIX/ and ' \
60 -e 'print $1,q|CU_TEST_NAME=`basename $(abs_srcdir)`,$$tst |,"\\\n"'
62 2007-01-11 Jim Meyering <jim@meyering.net>
64 Avoid a leak in expr's implementation of the ":" (match) operator.
65 * src/expr.c (docolon): Free the regexp buffer using regfree, rather
66 than doing it manually, being careful to set fastmap to NULL first.
67 Free any re_regs.start and .end members, if necessary.
69 * tests/misc/test-diag: Work also when libc's error function
70 reports the entire program name ("../../src/test"), rather than
71 just the final component.
73 2007-01-10 Jim Meyering <jim@meyering.net>
75 Don't use fts_statp uninitialized for "chown -RLh --preserve-root ...".
76 * src/chown-core.c (FTSENT_IS_DIRECTORY): New macro.
77 (change_file_owner): Perform the ROOT_DEV_INO_CHECK only for a
78 directory. Non-directory entries lack fts_statp data when using
79 the FTS_NOSTAT option.
81 2007-01-07 Jim Meyering <jim@meyering.net>
83 * tests/sample-test: Update copyright date to 2007.
84 * Makefile.maint (copyright-check): Also check the copyright date
87 2007-01-06 Jim Meyering <jim@meyering.net>
89 * tests/fmt/basic (pfx-only, pfx-of-pfx): New tests,
90 based on examples from G.P. Halkes in
91 <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/9388>.
93 2007-01-06 G.P. Halkes <buscom@ghalkes.nl>
95 * src/fmt.c (copy_rest): Correct prefix handling.
96 Don't elide a line with the prefix followed by only white space.
97 (get_line): Move EOF-check to loop-termination condition.
98 * tests/fmt/basic (pfx-1): Adjust test to expect desired result.
99 (pfx-2): Remove test; its premise was contrary to the documentation.
101 2007-01-05 Jim Meyering <jim@meyering.net>
103 Avoid a used-uninitialized bug for invalid input, i.e., when the size
104 of the input, not counting newlines, is 1 % 4.
105 * gl/lib/base64.c (base64_decode): Don't hard-code inlen==4.
106 It may be smaller when flushing.
108 2007-01-05 Mike Frysinger <vapier@gentoo.org>
110 * src/dircolors.hin: Add a TERM directive for cons25.
112 2007-01-04 Jim Meyering <jim@meyering.net>
114 * Makefile.cfg (local-checks-to-skip): Skip strftime-check, in
115 case you don't have convenient access to glibc info documentation.
117 Use the release year, not the current year.
118 * src/groups.sh (version): Use a better name: @RELEASE_YEAR@.
119 * src/Makefile.am (RELEASE_YEAR): Define it.
121 Thanks to a prod from Eric Blake.
123 Ensure that "group --version" always prints the current year.
124 * src/groups.sh (version): Use @CURRENT_YEAR@, rather than 2006.
125 * src/Makefile.am (.sh): Also substitute for @CURRENT_YEAR@.
126 Suggestion from Eric Blake.
128 When decoding, always allow newlines in input, with almost no
130 * src/base64.c (do_decode): Initialize decode context.
131 Call base64_decode one more time, after all input is processed.
132 (usage): When decoding, newlines are always accepted.
134 * tests/misc/base64: Add a bunch of tests, for the above.
135 * gl/lib/base64.c: Include <string.h>.
136 (base64_decode_ctx_init, get_4, decode_4): New functions.
137 (base64_decode): Efficiently handle interspersed newlines.
138 (base64_decode_alloc): Update signature.
139 * gl/lib/base64.h (struct base64_decode_context): Define.
140 (base64_decode_ctx_init): Add prototype.
141 (base64_decode, base64_decode_alloc): Update prototypes.
143 * gl/lib/base64.c: Copied from gnulib.
144 * gl/lib/base64.h: Likewise.
146 2007-01-03 Jim Meyering <jim@meyering.net>
148 * THANKS: Add Evan Hunt.
150 2007-01-03 Bruno Haible <bruno@clisp.org>
152 Avoid spurious test failures on MacOS X 10.3.9, in a German locale.
153 * tests/chown/deref: Apply lang-default.
154 * tests/misc/split-a: Likewise.
155 * tests/mv/reply-no: Likewise.
157 * src/copy.c (copy_internal): Use mkfifo as a fallback if mknod fails.
160 2007-01-02 Paul Eggert <eggert@cs.ucla.edu>
162 Now, "ls -FRL" always follows symbolic links on Linux.
163 * NEWS: Mention this bug fix.
164 * src/ls.c (gobble_file): Fix bug reported by
165 Nobuyuki Tsuchimura in
166 http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00152.html
167 where "ls -FRL" didn't follow a symbolic link in some cases on Linux.
168 * tests/ls/follow-slink: Add a test for this case.
170 2007-01-01 Jim Meyering <jim@meyering.net>
172 * tests/rm/fail-eperm: Revert last change. The PATH=... setting
173 is not honored at least on HP-UX 11.23 systems.
174 Instead, simply transform the actual output diagnostic.
175 Test failure reported by Bob Proulx.
177 2006-12-30 Jim Meyering <jim@meyering.net>
179 * bootstrap (gnulib_extra_files): Remove announce-gen.
180 * bootstrap.conf (gnulib_modules): Add it here instead, now that
183 * tests/misc/base64: Factor a long, repetitive string.
185 * src/c99-to-c89.diff: Adjust remove.c offsets.
187 Clean up after the change of 2006-12-28.
188 * src/remove.c (AD_pop_and_chdir): Change **DIRP parameter to *DIRP,
189 now that this function never modifies the pointer. Adjust comments
190 and code accordingly.
191 (remove_dir): Set "dirp" to NULL right after AD_pop_and_chdir call,
192 now that AD_pop_and_chdir no longer does that.
194 * tests/rm/fail-eperm: Avoid spurious differences (the error function
195 from latest glibc no longer prints the full program_name): so don't
196 invoke rm via ../../src/rm. Instead, invoke it via "PATH=../../src rm".
198 * tests/mv/acl (skip): Skip this test also if the destination
199 directory, which is on a different file system, lacks ACL support.
201 * src/copy.c (copy_reg): Rewrite a comment that was rendered
202 inaccurate by the 2006-10-18 change.
204 2006-12-28 Jim Meyering <jim@meyering.net>
206 When moving "up" the hierarchy, be careful to remove a just-emptied
207 directory before opening ".", to avoid trouble with file system
208 implementations that cache readdir results at opendir-time.
209 * src/remove.c (AD_pop_and_chdir): Add a file descriptor parameter.
210 Don't update **DIRP. Don't call fdopendir here.
211 (remove_dir): Call fdopendir here instead.
212 Report and patch from Mikulas Patocka:
213 <http://lists.gnu.org/archive/html/bug-coreutils/2006-12/msg00170.html>
215 2006-12-27 Jim Meyering <jim@meyering.net>
217 * src/tail.c (usage): Mention +N for --bytes and --lines.
218 Suggestion from Evan Hunt.
220 2006-12-26 Jim Meyering <jim@meyering.net>
222 * configure.ac: Require autoconf-2.61 and automake-1.10.
223 Without the former (even with autoconf-2.60), "make distcheck"
224 would fail (without the 2006-09-26 autoconf AC_CHECK_DECL fix),
225 due to an inttypes.h generated with CFLAGS including -pedantic.
226 With the old decl check, @HAVE_DECL_STRTOUMAX@ would be 0.
228 * Makefile.maint (VC-tag): Define, so as to gpg-sign each release
229 tag, using the release version number as the message.
230 (vc-dist): Use $(VC-tag), rather than "$(VC) tag".
232 2006-12-21 Paul Eggert <eggert@cs.ucla.edu>
234 * NEWS: dd bs= operands now silently override later ibs= and obs=,
236 * src/dd.c (scanargs): Implement it.
237 * tests/dd/misc (outbytes): Test it.
238 * doc/coreutils.texi (dd invocation): Specify that bs=N
239 overrides later ibs and obs, undoing part of the
240 previous change. (The behavior was wrong.)
242 2006-12-20 Jim Meyering <jim@meyering.net>
244 "rm -rf /etc/motd" (run by non-root) now prints a diagnostic.
245 * src/remove.c (remove_entry): Handle EACCES for a non-directory, too.
246 Don't let a non-directory get by with errno == EPERM, either.
247 Check the file type directly (using cached stat value), rather
248 than trying to guess it from errno values.
249 Karl Berry reported that a cross-partition "mv /etc/issue ~"
250 failed with the um,... suboptimal diagnostic,
251 "mv: cannot remove `/etc/issue': Not a directory".
252 * tests/rm/Makefile.am (TESTS): Add fail-eacces.
253 * tests/rm/fail-eacces: New file.
254 * NEWS: Mention that both mv and rm are affected.
256 "cut -f 2- A B" no longer triggers a double-free bug
257 * src/cut.c (cut_fields): Set file-scoped global to NULL after
258 freeing it. This avoids a double-free (and core dump on some systems)
259 for this usage: "echo 1>a; echo 2>b; cut -f2- a b". Reported by
260 James Hunt in <http://bugzilla.redhat.com/220312>.
261 * NEWS: List this bug fix.
262 * THANKS: Mention him.
263 * tests/misc/cut: New file.
264 * tests/misc/Makefile.am (TESTS): Add cut.
266 2006-12-15 Jim Meyering <jim@meyering.net>
268 * tests/cp/open-perm-race: Correct the gdb-existence check.
269 Don't run either subsequent gdb command in a sub-shell.
270 Reported by Thomas Schwinge.
271 * THANKS: bring up to date.
273 2006-12-14 Paul Eggert <eggert@cs.ucla.edu>
275 Make sure cp -p isn't too generous with file permissions.
276 * tests/cp/Makefile.am (TESTS): Add file-perm-race.
277 * tests/cp/file-perm-race: New file.
279 Ensure cp -pR --parents isn't too generous with parent permissions.
280 * tests/cp/Makefile.am (TESTS): Add parent-perm-race.
281 * tests/cp/parent-perm-race: New file.
283 2006-12-14 Jim Meyering <jim@meyering.net>
285 * tests/chgrp/default-no-deref: Don't assume that files are created
286 with the primary group by default. That's not true in a directory
287 with the set-GID bit set.
289 Don't hang when there's no input tty.
290 * tests/cp/open-perm-race: Skip this test if there is no
291 controlling input `terminal'.
293 Test for a hard-to-detect race fix, using gdb.
294 * tests/cp/open-perm-race: New file, to test for the
295 cp --preserve=ownership fix of 2006-12-06.
297 * tests/cp/Makefile.am (TESTS_ENVIRONMENT): Define abs_top_builddir.
298 (TESTS): Add open-perm-race.
300 * src/chgrp.c (main): Don't prohibit -RLh, aka -RL with --no-dereference.
301 * src/chown.c (main): Likewise.
302 * src/chown-core.c (change_file_owner): Add to a comment.
303 * tests/chown/preserve-root: Add tests.
305 * NEWS: --preserve-root now works with chgrp, chmod, and chown.
306 * src/chmod.c (process_file): Do honor the --preserve-root option.
307 * src/chown-core.c (change_file_owner): Likewise, but here, also
308 handle the case in which a traversal would go "through" a symlink
309 to root. Reported by Matthew M. Boedicker
310 * tests/chown/preserve-root: Test for the above.
311 * tests/chown/Makefile.am (TESTS): Add preserve-root.
313 * NEWS: Mention the chmod fix induced by the 2006-12-11 change
314 to gnulib's m4/openat.m4.
316 2006-12-13 Andreas Schwab <schwab@suse.de>
318 Don't fail if mv/acl test succeeds.
319 * tests/mv/acl (skip): Check for acl support in the file system.
320 * tests/mv/Makefile.am (XFAIL_TESTS): Remove.
321 (TESTS_ENVIRONMENT): Pass CONFIG_HEADER.
323 2006-12-13 Paul Eggert <eggert@cs.ucla.edu>
325 Remove some arbitrary restrictions on size fields, so that
326 commands like "sort -k 18446744073709551616" no longer fail merely
327 because 18446744073709551616 doesn't fit in uintmax_t. The trick
328 is that these fields can all be treated as effectively infinity;
329 their exact values don't matter, since no internal buffer can be
331 * src/join.c (string_to_join_field): Verify that SIZE_MAX <=
332 ULONG_MAX if the code assumes this. Silently truncate too-large
333 values to SIZE_MAX, as the remaining code will do the right thing
335 * src/sort.c (parse_field_count): Likewise.
336 * src/uniq.c (size_opt, main): Likewise.
337 * tests/join/Test.pm (bigfield): New test.
338 * tests/sort/Test.pm (bigfield): New test.
339 * tests/uniq/Test.pm (121): New test.
341 2006-12-13 Jim Meyering <jim@meyering.net>
343 * tests/chgrp/default-no-deref: New test.
344 * tests/chgrp/Makefile.am (TESTS): Add default-no-deref.
346 2006-12-12 Jim Meyering <jim@meyering.net>
348 * src/system.h (SETVBUF): Remove definition, now that the
349 autoconf macro, AC_FUNC_SETVBUF_REVERSED, does nothing.
350 * src/tee.c (tee_files): s/SETVBUF/setvbuf/.
351 * src/od.c (open_next_file): Likewise.
353 2006-12-09 Jim Meyering <jim@meyering.net>
355 * man/Makefile.am (.x.1): Make help2man use $(PACKAGE_STRING) as the
356 "source". I.e. "GNU coreutils 6.7".
358 * NEWS: With the change from "-pre" to "-dirty" suffix, also change
359 from NEXT_VER-pre to CUR_VER-dirty. So, this is 6.7-dirty.
360 * configure.ac (AC_INIT): s/6.8-dirty/6.7-dirty/.
362 * tests/uniq/Test.pm (test_vector): Skip the pipe-reading test
363 whenever uniq is expected to fail. This should catch the other case
364 [test #112] in which uniq emits "cat: write error: Broken pipe" on
367 2006-12-08 Jim Meyering <jim@meyering.net>
369 Include bootstrap tool version info in the announcement form.
370 * Makefile.maint (gnulib_snapshot_date): Define.
371 (announcement): Use two new announce-gen options,
372 --bootstrap-tools and --gnulib-snapshot-date.
373 * Makefile.cfg (gnulib_dir): Set.
375 Post-release version change.
376 * NEWS: Add a line for 6.8-dirty.
377 * configure.ac (AC_INIT): Set new version string.
379 2006-12-07 Jim Meyering jim@meyering.net
382 * NEWS: Record release date. Remove '-pre' suffix.
383 * configure.ac (AC_INIT): Remove version string suffix.
385 2006-12-07 Jim Meyering <jim@meyering.net>
387 Make the output of "make check" more reproducible.
388 * tests/touch/empty-file: Use envvar-check, so "make check" doesn't
389 evoke diagnostics like this when COLUMNS=0 in the environment:
390 ls: ignoring invalid width in environment variable COLUMNS: 0
391 * tests/touch/no-rights: Likewise.
392 * tests/help-version: Likewise.
393 * tests/uniq/Test.pm: Don't perform the pipe-reading version of test
394 118, since it emits "cat: write error: Broken pipe" on some systems.
396 2006-12-06 Paul Eggert <eggert@cs.ucla.edu>
398 * NEWS: Document the cp -p fix for special bits.
399 * src/copy.c (set_owner): Now returns a three-way result, so
400 that the caller can clear the special bits. All callers changed.
401 (copy_reg): Don't set the special bits if chown failed.
402 (copy_internal): Likewise.
403 * tests/cp/special-bits: Test this fix.
405 2006-12-06 Paul Eggert <eggert@cs.ucla.edu>
407 * NEWS: Document the cp --preserve=ownership fix.
408 * m4/jm-macros.m4 (coreutils_MACROS): Check for fchmod.
409 * src/copy.c (fchmod_or_lchmod): New function.
410 (copy_reg): New arg OMITTED_PERMISSIONS. All uses changed.
411 Omit confusing and unused ", dst_mode" arg to 'open' without O_CREAT.
412 When creating a file, use O_EXCL, so we're more likely to detect
413 funny business by other processes. At the end, if permissions
414 were omitted, chmod them back in.
415 (copy_internal): If the ownership might change, omit some permissions
416 at first, then restore them after chowning the file.
417 * src/cp.c (make_dir_parents_private): Likewise.
418 * src/copy.c (cached_umask): New function.
419 * src/copy.h (cached_umask): New decl.
421 2006-12-06 Jim Meyering <jim@meyering.net>
423 Make the output of "make check" more reproducible.
424 * tests/misc/date-sec: Don't emit any diagnostic about sleeping.
426 2006-12-03 Paul Eggert <eggert@cs.ucla.edu>
428 * src/install.c (install_file_in_file): Preserve time stamps
429 before changing owner or file mode bits, for consistency with
430 other coreutils programs.
432 2006-12-03 Jim Meyering <jim@meyering.net>
434 * tests/misc/date-sec: Output a fixed string.
436 * NEWS: du --one-file-system (-x) would skip subdirectories of any
437 directory listed as second or subsequent command line argument.
438 * tests/du/one-file-system: New file. Test for today's fts.c fix.
439 * tests/du/Makefile.am (TESTS): Add one-file-system.
440 Reported by Mike Frysinger.
442 2006-12-02 Jim Meyering <jim@meyering.net>
444 * tests/du/basic: Generate 4KB file simply using printf, rather than
445 seq+head. This avoids a spurious "Broken pipe" diagnostic from seq.
447 2006-11-28 Jim Meyering <jim@meyering.net>
449 * tests/mv/no-target-dir: Detect a buggy rename syscall. If found,
450 skip this test. This happens at least on ia64 linux-2.4.19 w/ext3.
451 Reported by Matthew Woehlke.
453 * tests/mv/dir2dir: Also accept EBUSY.
454 Reported by Matthew Woehlke.
456 2006-11-27 Jim Meyering <jim@meyering.net>
458 * Makefile.maint (patch-check): Rewrite to diagnose failure.
459 * src/c99-to-c89.diff: Adjust shred.c offsets.
461 2006-11-26 Paul Eggert <eggert@cs.ucla.edu>
463 Improve the check for departures from C89, and fix the departures
465 * Makefile.maint (my-distcheck): Also check for C89 compatibility
466 as best we can with GCC.
467 * src/stat.c (PRINTF_OPTION): Omit comma before } in enum
468 declaration; C89 doesn't allow this.
469 * src/dcgen: Don't generate string literals longer than
470 what C89 requires support for.
471 * src/cut.c (usage): Don't use string literals longer than
472 what C89 requires support for.
473 * src/date.c (usage): Likewise.
474 * src/dd.c (usage): Likewise.
475 * src/du.c (usage): Likewise.
476 * src/ls.c (usage): Likewise.
477 * src/od.c (usage): Likewise.
478 * src/readlink.c (usage): Likewise.
479 * src/seq.c (usage): Likewise.
480 * src/shred.c (usage): Likewise.
482 2006-11-26 Mike Frysinger <vapier@gentoo.org>
484 Recognize new archive, audio and image formats.
485 Give audio files a separate color.
486 * src/dircolors.hin: Add comments for common .sh and .csh scripts.
487 Add .bz2, .tbz2, .tz, .rar, .ace, .zoo, .cpio, .7z, .rz as archive
488 suffixes. Add .mng, .pcx, .m2v, .mkv, .ogm, .mp4, .m4v, .mp4v, .vob,
489 .qt, .nuv, .wmv, .asf, .rm, .rmvb, .flc, .yuv as image formats.
490 Add .aac, .au, .mid, .midi, .mka, .ra as audio suffixes. Change
491 audio color to 00;36 to differentiate from image/video color.
493 2006-11-26 Jim Meyering <jim@meyering.net>
495 * Makefile.maint (patch-check): Compile patched sources with
496 CFLAGS='-Wdeclaration-after-statement -Werror', to ensure that
497 no violations remain.
499 * src/c99-to-c89.diff: Remove 3 bogus hunks.
501 * src/remove.c (fd_to_subdirp): Remove unused parameter, ds.
504 * src/c99-to-c89.diff: Adjust for changes in rm.c and in remove.c.
506 * src/rm.c (main): Remove unnecessary (assuming C99) braces.
508 2006-11-26 Paul Eggert <eggert@cs.ucla.edu>
510 Port parts of the code to C89 to minimize the need for c99-to-c89.diff,
511 while trying to retain the readability of C99 as much as possible.
512 * src/remove.c (rm_1): Remove decl of local, fd_cwd.
513 Replace each of two uses with literal AT_FDCWD.
514 (cache_stat_init): Return its argument, for convenience.
515 Update the caller in remove_dir.
516 (AD_pop_and_chdir): Return prev_dir rather than storing through
517 a pointer argument. All uses changed.
518 (AD_ensure_initialized): New function.
519 (AD_mark_helper): Use it, to avoid the need for declaration
521 (rm): Move cycle_check_init call into callee...
523 Use an else clause in place of a "continue" statement.
524 (close_preserve_errno): Remove.
525 (fd_to_subdirp): Rewrite to avoid the need for decl after statement.
527 2006-11-25 Jim Meyering <jim@meyering.net>
529 * Makefile.am (EXTRA_DIST): Remove announce-gen from here, too.
531 2006-11-24 Theodoros V. Kalamatianos <thkala@softlab.ece.ntua.gr> (tiny change)
533 * tests/du/inacc-dest: Skip this test when running as root.
535 2006-11-23 Jim Meyering <jim@meyering.net>
537 * announce-gen: Remove file. It's moving to gnulib.
538 * bootstrap: Pull it from gnulib/build-aux instead.
539 * Makefile.maint (announcement): Reflect move to ./build-aux.
541 * tests/du/deref-args: Use "printf %65536s x" to create a 64KB file,
542 rather than a pipeline that would sometimes evoke a diagnostic
543 like "seq: write error: Broken pipe".
545 * tests/help-version: Suppress dd transfer rate output.
547 * configure.ac (AC_INIT): Bump to 6.7-pre, not 6.6-pre.
549 2006-11-22 Jim Meyering <jim@meyering.net>
551 * announce-gen (print_news_deltas): Fix silly, but harmless typo:
552 change "(:?..." to "(?:..." in regexps.
554 Post-release version change.
555 * NEWS: Add a line for 6.7-pre.
556 * configure.ac (AC_INIT): Bump to 6.7 and add "-pre" suffix.
559 * NEWS: Record release date. Remove "-pre" suffix.
560 * configure.ac (AC_INIT): Remove "-pre" suffix from version string.
562 * announce-gen: Remove unused --release-archive-directory option.
563 (print_news_deltas): Accept new adjective, "Noteworthy", in addition
565 Match version numbers in NEWS using tighter regular expressions.
566 (main): Require the --gpg-key-id=ID option.
567 * Makefile.maint (announcement): Don't use now-removed
568 --release-archive-directory=... option.
570 * NEWS: Mention the three noteworthy changes, all fixed via gnulib.
572 2006-11-21 Jim Meyering <jim@meyering.net>
574 * tests/rm/one-file-system: Upon setup failure (e.g., mount failure),
575 skip the test rather than failing. Reported by Michael Deutschmann.
577 * tests/rm/fail-eperm: Use the "(exit N); exit N" idiom,
578 rather than just "exit N".
580 Arrange for "make check-root" to run the new root-only test.
581 * tests/Makefile.am (t7): New target, to run tests/ls/nameless-uid.
584 2006-11-20 Jim Meyering <jim@meyering.net>
586 Add a root-only test for today's lib/idcache.c fix.
587 * tests/ls/nameless-uid: New file.
588 * tests/ls/Makefile.am (TESTS): Add nameless-uid.
589 (TESTS_ENVIRONMENT): Add PERL to the list.
591 2006-11-19 Jim Meyering <jim@meyering.net>
593 * tests/tail-2/assert-2: Mark as a very-expensive test, because I
594 find the 7-second sleep annoyingly long. Besides, this test is
595 probably far too specific and timing sensitive ever to trigger again.
596 * tests/tail-2/assert: Likewise.
598 Post-release version change.
599 * NEWS: Add a line for 6.6-pre.
600 * configure.ac (AC_INIT): Bump to 6.6 and add "-pre" suffix.
603 * NEWS: Record release date. Remove "-cvs" suffix.
604 * configure.ac (AC_INIT): Remove "-cvs" suffix from version string.
606 2006-11-18 Jim Meyering <jim@meyering.net>
608 "ln --backup f f" produces a misleading diagnostic:
609 ln: creating hard link `f' => `f': No such file or directory
610 * src/ln.c (do_link): Give a better diagnostic in this unusual case.
611 (do_link): Rename local: s/lstat_ok/dest_lstat_ok/.
612 * tests/ln/Makefile.am (TESTS): Add hard-backup.
613 * tests/ln/hard-backup: New test for the above.
614 * NEWS: Mention this fix.
616 2006-11-16 Paul Eggert <eggert@cs.ucla.edu>
618 * bootstrap.conf (gnulib_modules): Add sys_stat, since we use it
620 * lib/.cvsignore, lib/.gitignore: Add root-dev-ino.c, root-dev-ino.h.
621 * m4/.cvsignore, m4/.gitignore: Add root-dev-ino.m4.
622 * src/ls.c (DIRED_FPUTS_LITERAL, PUSH_CURRENT_DIRED_POS):
623 Omit unnecessary parenthesization of args.
624 * src/od.c (EQUAL_BLOCKS): Likewise.
625 * src/system.h (STREQ, ASSIGN_STRDUPA): Likewise.
627 2006-11-16 Jim Meyering <jim@meyering.net>
629 * tests/tail-2/append-only: If chattr +a fails, exit 77 (to tell
630 automake we're skipping this test), and give a diagnostic to tell
631 the user the same thing. Reported by Mike Grayson.
633 2006-11-16 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
635 * man/Makefile.am (dist_man_MANS): Replace all optional manpages
636 with `$(MAN)', computed at configure time; also, list them ...
637 (optional_mans): ... in this new variable.
638 (max_aux, EXTRA_DIST): Ensure that we distribute all manpages.
640 2006-11-16 Jim Meyering <jim@meyering.net>
642 Help valgrind see that there is no leak in dd.c.
643 * src/dd.c (dd_copy): Declare real_buf and real_obuf to be static,
644 so we need not free them at all. This is easier than freeing
645 both buffers at each of the early "return"s.
647 * src/csplit.c (load_buffer): Plug an inconsequential leak.
649 2006-11-15 Jim Meyering <jim@meyering.net>
651 * .x-po-check: Exclude gl/ files. Otherwise, po-check would
652 complain that some of gl/lib/*.[ch] are not listed in POTFILES.in.
654 2006-11-14 Jim Meyering <jim@meyering.net>
656 * gl/m4/root-dev-ino.m4: Now that this is part of a real "module",
657 remove the now-unnecessary use of AC_LIBSOURCES.
659 Adapt to new version of gnulib-tool.
660 * gl/modules/root-dev-ino: New file.
661 * lib/root-dev-ino.c, lib/root-dev-ino.h: Move these files ...
662 * gl/lib/root-dev-ino.c, gl/lib/root-dev-ino.h: ... to here.
663 * m4/root-dev-ino.m4: Move this file ...
664 * gl/m4/root-dev-ino.m4: ... to here.
666 * bootstrap.conf (gnulib_modules): Add root-dev-ino.
668 2006-11-13 Jim Meyering <jim@meyering.net>
670 * src/sort.c (insertkey): Use xmemdup, rather than xmalloc+assignment.
673 Plug another technically-unimportant leak in sort.
674 * src/sort.c (main): Don't allocate memory for each new key here.
675 (insertkey): Allocate memory for each key here, instead.
676 (key_init): Rename from new_key. Don't allocate.
678 * src/sort.c (main): Plug a tiny memory leak.
679 Move declaration of local "minus" down to be nearer point of use.
681 2006-11-12 Jim Meyering <jim@meyering.net>
683 du would exit early, when encountering an inaccessible directory
684 Reported by Mike Frysinger, in
685 http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/8831
686 * tests/du/inacc-dest: New test, based on an example from Mike Frysinger.
687 * tests/chgrp/no-x: Remove the "fts_read failed: ..."
688 diagnostic from the expected output when using native fdopendir.
689 * tests/chmod/no-x: Likewise.
690 * tests/du/no-x: Likewise.
691 * NEWS: Mention this bug fix.
692 * tests/du/Makefile.am (TESTS): Add inacc-dest.
694 * Makefile.maint (sc_cast_of_x_alloc_return_value): Add an exclusion
697 Avoid false-positive when testing via valgrind.
698 * tests/mv/atomic: Grep strace output for a more specific pattern
699 than just "unlink", since that got a false positive when testing
700 under valgrind: unlink("/tmp/valgrind_proc_9657_cmdline_A51E9991") = 0
701 * tests/mv/Makefile.am (TESTS_ENVIRONMENT): Define EGREP.
703 2006-10-28 Jim Meyering <jim@meyering.net>
705 * Makefile.maint (patch-check): Make it easier to regenerate
706 the src/c99-to-c89.diff file. E.g., I do this:
707 make patch-check REGEN_PATCH=1; ediff src/c99-to-c89.diff new-diff
709 * src/c99-to-c89.diff: Update to reflect new offsets in rm.c.
711 2006-10-26 Jim Meyering <jim@meyering.net>
713 * src/system.h (ftello): Add a compile-time check for the highly
714 unlikely condition of off_t narrower than long int, rather than
715 handling it at run time. Based on a patch from Paul Eggert.
717 2006-10-25 Paul Eggert <eggert@cs.ucla.edu>
719 * tests/chmod/c-option: When double-quoting part of a word, prefer
720 to double-quote the whole word. This is a bit easier to read (at
721 least for me), and in some cases it avoids a shell bug with Tru64
722 4.0 sh reported by Nelson H. F. Beebe. For example, instead of
723 "$abs_srcdir"/../setgid-check we now write
724 "$abs_srcdir/../setgid-check".
725 * tests/cp/cp-parents: Likewise.
726 * tests/du/inaccessible-cwd: Likewise.
727 * tests/du/long-from-unreadable: Likewise.
728 * tests/install/basic-1: Likewise.
729 * tests/install/trap: Likewise.
730 * tests/misc/close-stdout: Likewise.
731 * tests/mkdir/concurrent-1: Likewise.
732 * tests/mkdir/p-1: Likewise.
733 * tests/mkdir/p-3: Likewise.
734 * tests/mkdir/parents: Likewise.
735 * tests/mkdir/perm: Likewise.
736 * tests/readlink/can-e: Likewise.
737 * tests/readlink/can-f: Likewise.
738 * tests/readlink/can-m: Likewise.
739 * tests/rm/inaccessible: Likewise.
740 * tests/rm/unread3: Likewise.
741 * tests/touch/no-create-missing: Likewise.
743 * lib/.cvsignore: Add uinttostr.c.
745 2006-10-25 Jim Meyering <jim@meyering.net>
747 Portability to Tru64 V4.0.
748 * src/system.h (ftello) [!HAVE_FSEEKO && !defined ftello]:
749 Define inline replacement function.
750 This (along with a yesterday's fix for autoconf's
751 _AC_SYS_LARGEFILE_MACRO_VALUE macro) makes it so coreutils
752 now builds once more on Tru64 V4.0. Reported by Nelson Beebe.
754 2006-10-25 Bruno Haible <bruno@clisp.org>
756 * src/cat.c (infile): Add "const" to declaration.
757 * src/csplit.c (prefix): Likewise.
758 * src/printf.c (cfcc_msg): Likewise.
759 * src/tail.c (valid_file_spec): Likewise.
760 * src/cut.c (cut_file): Likewise, for a parameter.
761 * src/expr.c (str_value): Likewise.
762 * src/fold.c (fold_file): Likewise.
763 * src/pr.c (init_header): Likewise.
764 * src/dircolors.c (dc_parse_stream): Likewise, for a local.
765 * src/tr.c (make_printable_str): Likewise.
766 * src/nl.c (body_type, header_type, footer_type, current_type):
767 (separator_str, build_type_arg, nl_file): Likewise, for many.
768 * src/paste.c (main): Don't assign a read-only string to 'optarg'.
769 * src/tac.c (separator, tac_seekable, copy_to_temp): Likewise.
771 2006-10-25 Jim Meyering <jim@meyering.net>
773 * tests/sample-test: Update copyright year list to include only
774 the current year, since this is what I'll want in any new test.
776 2006-10-24 Jim Meyering <jim@meyering.net>
778 * src/c99-to-c89.diff: Update to reflect new offsets.
780 * NEWS: new feature: rm accepts new option: --one-file-system
781 Suggested by Steve McIntyre in <http://bugs.debian.org/392925>.
782 * src/remove.h (struct rm_options) [one_file_system]: New member.
783 * src/rm.c (rm_option_init): Initialize it.
784 (usage): Document the option.
785 * src/mv.c (rm_option_init): Likewise.
786 * src/remove.c (remove_dir): With --one-file-system and --recursive,
787 for each directory command line argument, do not affect a file system
788 different from that of the starting directory. And give a diagnostic.
789 * src/rm.c (ONE_FILE_SYSTEM): New enum.
790 (main): Handle new option.
791 * tests/rm/one-file-system: Test the above.
792 * tests/rm/Makefile.am (TESTS): Add one-file-system.
793 * tests/Makefile.am (check-root): Add the rm/one-file-system
795 (EXTRA_DIST): Add other-fs-tmpdir.
797 * tests/mv/setup: Removed. Renamed to...
798 * tests/other-fs-tmpdir: ...this new file.
799 * tests/mv/Makefile.am (EXTRA_DIST): Remove setup.
800 * tests/mv/acl: Reflect renaming: use ../other-fs-tmpdir.
801 * tests/mv/backup-is-src: Likewise.
802 * tests/mv/hard-link-1: Likewise.
803 * tests/mv/leak-fd: Likewise.
804 * tests/mv/mv-special-1: Likewise.
805 * tests/mv/part-fail: Likewise.
806 * tests/mv/part-hardlink: Likewise.
807 * tests/mv/part-rename: Likewise.
808 * tests/mv/part-symlink: Likewise.
809 * tests/mv/partition-perm: Likewise.
810 * tests/mv/to-symlink: Likewise.
811 * tests/mv/into-self-2: Likewise.
813 Don't let a failure in one test stop "make -k" from running the others.
814 * tests/Makefile.am (t1 t2 t3 t4 t5): New targets.
815 (check-root): Depend on them, rather than executing the five
816 commands in a single rule. Reported by Greg Schafer.
818 2006-10-23 Bob Proulx <bob@proulx.com> (tiny change)
820 * Makefile.maint (alpha beta major): Use a better log message for
821 the automatic commit of .prev-version.
823 2006-10-23 Jim Meyering <jim@meyering.net>
825 * tests/misc/pwd-long: Undo last change, since it made Perl invoke
826 pwd via a shell. Instead, ensure that the absolute name of the
827 pwd binary consists solely of reasonable characters.
828 Whoops. Don't exec the perl script. Otherwise, the sh-trap-based
829 clean-up code isn't run.
831 * NEWS: Add a line for 6.5-cvs.
832 * configure.ac (AC_INIT): Bump to 6.5 and add "-cvs" suffix.
834 2006-10-22 Jim Meyering <jim@meyering.net>
838 * NEWS: Record the 6.4 release date.
839 * configure.ac (AC_INIT): Remove "-cvs" suffix from version string.
841 * Makefile.maint: Complete the adaptation to function with a working
842 directory that is using git (rather than cvs) for version control.
844 2006-10-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
846 * tests/chmod/c-option: Double-quote instances of `$abs_srcdir'.
847 * tests/cp/cp-parents: Likewise.
848 * tests/mkdir/parents: Likewise.
849 * tests/mkdir/perm: Likewise.
851 * tests/sample-test: Quote variables containing absolute build
852 tree paths. In the cleanup trap, make sure `cd' succeeds before
853 `chmod'ing and `rm'ing the temporary files.
854 * tests/chgrp/basic: Likewise.
855 * tests/chgrp/deref: Likewise.
856 * tests/chgrp/no-x: Likewise.
857 * tests/chgrp/posix-H: Likewise.
858 * tests/chgrp/recurse: Likewise.
859 * tests/chmod/c-option: Likewise.
860 * tests/chmod/equal-x: Likewise.
861 * tests/chmod/equals: Likewise.
862 * tests/chmod/inaccessible: Likewise.
863 * tests/chmod/no-x: Likewise.
864 * tests/chmod/octal: Likewise.
865 * tests/chmod/setgid: Likewise.
866 * tests/chmod/umask-x: Likewise.
867 * tests/chmod/usage: Likewise.
868 * tests/chown/basic: Likewise.
869 * tests/chown/deref: Likewise.
870 * tests/chown/separator: Likewise.
871 * tests/cp/acl: Likewise.
872 * tests/cp/backup-1: Likewise.
873 * tests/cp/backup-dir: Likewise.
874 * tests/cp/backup-is-src: Likewise.
875 * tests/cp/cp-HL: Likewise.
876 * tests/cp/cp-deref: Likewise.
877 * tests/cp/cp-i: Likewise.
878 * tests/cp/cp-mv-backup: Likewise.
879 * tests/cp/cp-parents: Likewise.
880 * tests/cp/deref-slink: Likewise.
881 * tests/cp/dir-rm-dest: Likewise.
882 * tests/cp/dir-slash: Likewise.
883 * tests/cp/dir-vs-file: Likewise.
884 * tests/cp/fail-perm: Likewise.
885 * tests/cp/into-self: Likewise.
886 * tests/cp/link: Likewise.
887 * tests/cp/link-no-deref: Likewise.
888 * tests/cp/link-preserve: Likewise.
889 * tests/cp/no-deref-link1: Likewise.
890 * tests/cp/no-deref-link2: Likewise.
891 * tests/cp/no-deref-link3: Likewise.
892 * tests/cp/perm: Likewise.
893 * tests/cp/preserve-2: Likewise.
894 * tests/cp/r-vs-symlink: Likewise.
895 * tests/cp/same-file: Likewise.
896 * tests/cp/slink-2-slink: Likewise.
897 * tests/cp/sparse: Likewise.
898 * tests/cp/special-bits: Likewise.
899 * tests/cp/src-base-dot: Likewise.
900 * tests/cp/symlink-slash: Likewise.
901 * tests/dd/not-rewound: Likewise.
902 * tests/dd/skip-seek2: Likewise.
903 * tests/dd/unblock-sync: Likewise.
904 * tests/du/2g: Likewise.
905 * tests/du/8gb: Likewise.
906 * tests/du/basic: Likewise.
907 * tests/du/deref: Likewise.
908 * tests/du/deref-args: Likewise.
909 * tests/du/exclude: Likewise.
910 * tests/du/fd-leak: Likewise.
911 * tests/du/hard-link: Likewise.
912 * tests/du/inaccessible-cwd: Likewise.
913 * tests/du/long-from-unreadable: Likewise.
914 * tests/du/long-sloop: Likewise.
915 * tests/du/no-deref: Likewise.
916 * tests/du/no-x: Likewise.
917 * tests/du/restore-wd: Likewise.
918 * tests/du/slash: Likewise.
919 * tests/du/slink: Likewise.
920 * tests/du/trailing-slash: Likewise.
921 * tests/du/two-args: Likewise.
922 * tests/fmt/long-line: Likewise.
923 * tests/install/basic-1: Likewise.
924 * tests/install/create-leading: Likewise.
925 * tests/install/d-slashdot: Likewise.
926 * tests/install/trap: Likewise.
927 * tests/ln/misc: Likewise.
928 * tests/ln/target-1: Likewise.
929 * tests/ls/color-dtype-dir: Likewise.
930 * tests/ls/dangle: Likewise.
931 * tests/ls/dired: Likewise.
932 * tests/ls/file-type: Likewise.
933 * tests/ls/follow-slink: Likewise.
934 * tests/ls/infloop: Likewise.
935 * tests/ls/inode: Likewise.
936 * tests/ls/m-option: Likewise.
937 * tests/ls/no-arg: Likewise.
938 * tests/ls/recursive: Likewise.
939 * tests/ls/rt-1: Likewise.
940 * tests/ls/stat-dtype: Likewise.
941 * tests/ls/stat-failed: Likewise.
942 * tests/ls/stat-vs-dirent: Likewise.
943 * tests/misc/cat-proc: Likewise.
944 * tests/misc/close-stdout: Likewise.
945 * tests/misc/csplit: Likewise.
946 * tests/misc/date-sec: Likewise.
947 * tests/misc/false-status: Likewise.
948 * tests/misc/head-c: Likewise.
949 * tests/misc/head-pos: Likewise.
950 * tests/misc/mknod: Likewise.
951 * tests/misc/nl: Likewise.
952 * tests/misc/nohup: Likewise.
953 * tests/misc/pathchk1: Likewise.
954 * tests/misc/printf: Likewise.
955 * tests/misc/printf-hex: Likewise.
956 * tests/misc/pwd-long: Likewise.
957 * tests/misc/shuf: Likewise.
958 * tests/misc/sort-rand: Likewise.
959 * tests/misc/split-a: Likewise.
960 * tests/misc/split-fail: Likewise.
961 * tests/misc/split-l: Likewise.
962 * tests/misc/stat-fmt: Likewise.
963 * tests/misc/tac-continue: Likewise.
964 * tests/misc/wc-files0: Likewise.
965 * tests/mkdir/concurrent-1: Likewise.
966 * tests/mkdir/p-1: Likewise.
967 * tests/mkdir/p-2: Likewise.
968 * tests/mkdir/p-3: Likewise.
969 * tests/mkdir/p-slashdot: Likewise.
970 * tests/mkdir/p-thru-slink: Likewise.
971 * tests/mkdir/p-v: Likewise.
972 * tests/mkdir/parents: Likewise.
973 * tests/mkdir/perm: Likewise.
974 * tests/mkdir/t-slash: Likewise.
975 * tests/mv/acl: Likewise.
976 * tests/mv/atomic: Likewise.
977 * tests/mv/backup-dir: Likewise.
978 * tests/mv/childproof: Likewise.
979 * tests/mv/diag: Likewise.
980 * tests/mv/dir-file: Likewise.
981 * tests/mv/dir2dir: Likewise.
982 * tests/mv/dup-source: Likewise.
983 * tests/mv/hard-2: Likewise.
984 * tests/mv/hard-3: Likewise.
985 * tests/mv/hard-4: Likewise.
986 * tests/mv/hard-link-1: Likewise.
987 * tests/mv/hard-verbose: Likewise.
988 * tests/mv/i-2: Likewise.
989 * tests/mv/i-3: Likewise.
990 * tests/mv/i-4: Likewise.
991 * tests/mv/i-5: Likewise.
992 * tests/mv/i-link-no: Likewise.
993 * tests/mv/into-self-4: Likewise.
994 * tests/mv/leak-fd: Likewise.
995 * tests/mv/mv-special-1: Likewise.
996 * tests/mv/no-target-dir: Likewise.
997 * tests/mv/part-fail: Likewise.
998 * tests/mv/part-hardlink: Likewise.
999 * tests/mv/part-rename: Likewise.
1000 * tests/mv/part-symlink: Likewise.
1001 * tests/mv/partition-perm: Likewise.
1002 * tests/mv/perm-1: Likewise.
1003 * tests/mv/reply-no: Likewise.
1004 * tests/mv/trailing-slash: Likewise.
1005 * tests/mv/update: Likewise.
1006 * tests/od/od-N: Likewise.
1007 * tests/od/x8: Likewise.
1008 * tests/readlink/can-e: Likewise.
1009 * tests/readlink/can-f: Likewise.
1010 * tests/readlink/can-m: Likewise.
1011 * tests/readlink/rl-1: Likewise.
1012 * tests/rm/cycle: Likewise.
1013 * tests/rm/dangling-symlink: Likewise.
1014 * tests/rm/deep-1: Likewise.
1015 * tests/rm/dir-no-w: Likewise.
1016 * tests/rm/dir-nonrecur: Likewise.
1017 * tests/rm/dot-rel: Likewise.
1018 * tests/rm/empty-inacc: Likewise.
1019 * tests/rm/f-1: Likewise.
1020 * tests/rm/fail-2eperm: Likewise.
1021 * tests/rm/hash: Likewise.
1022 * tests/rm/i-1: Likewise.
1023 * tests/rm/i-no-r: Likewise.
1024 * tests/rm/ignorable: Likewise.
1025 * tests/rm/inaccessible: Likewise.
1026 * tests/rm/interactive-always: Likewise.
1027 * tests/rm/interactive-once: Likewise.
1028 * tests/rm/ir-1: Likewise.
1029 * tests/rm/isatty: Likewise.
1030 * tests/rm/no-give-up: Likewise.
1031 * tests/rm/r-1: Likewise.
1032 * tests/rm/r-2: Likewise.
1033 * tests/rm/r-3: Likewise.
1034 * tests/rm/r-4: Likewise.
1035 * tests/rm/readdir-bug: Likewise.
1036 * tests/rm/rm1: Likewise.
1037 * tests/rm/rm2: Likewise.
1038 * tests/rm/rm3: Likewise.
1039 * tests/rm/rm4: Likewise.
1040 * tests/rm/rm5: Likewise.
1041 * tests/rm/sunos-1: Likewise.
1042 * tests/rm/unread2: Likewise.
1043 * tests/rm/unread3: Likewise.
1044 * tests/rmdir/fail-perm: Likewise.
1045 * tests/rmdir/t-slash: Likewise.
1046 * tests/shred/exact: Likewise.
1047 * tests/shred/remove: Likewise.
1048 * tests/sum/sysv: Likewise.
1049 * tests/tail-2/append-only: Likewise.
1050 * tests/tail-2/assert: Likewise.
1051 * tests/tail-2/assert-2: Likewise.
1052 * tests/tail-2/big-4gb: Likewise.
1053 * tests/tail-2/fflush: Likewise.
1054 * tests/tail-2/infloop-1: Likewise.
1055 * tests/tail-2/proc-ksyms: Likewise.
1056 * tests/tail-2/start-middle: Likewise.
1057 * tests/tail-2/tail-n0f: Likewise.
1058 * tests/tee/basic: Likewise.
1059 * tests/tee/dash: Likewise.
1060 * tests/touch/fail-diag: Likewise.
1061 * tests/touch/no-create-missing: Likewise.
1062 * tests/touch/not-owner: Likewise.
1063 * tests/touch/obsolescent: Likewise.
1064 * tests/touch/read-only: Likewise.
1065 * tests/touch/relative: Likewise.
1067 2006-10-21 Jim Meyering <jim@meyering.net>
1069 * NEWS: (cp --backup fix): Fix a typo.
1071 * .gitignore: Remove some references to files in subdirectories.
1072 * build-aux/.gitignore, doc/.gitignore, lib/.gitignore: New files.
1073 * m4/.gitignore, po/.gitignore, src/.gitignore: Likewise.
1075 * src/copy.c (copy_internal): Add a comment saying why we prefer
1078 Enable an fts optimization (call lstat only for directories,
1079 on some file system types) also with the --preserve-root option
1081 * src/chown-core.c (change_file_owner): Compare fts_statp-based
1082 dev/ino against root dev/ino only for directories.
1083 (chown_files): Don't let the root_dev_ino setting influence whether
1084 we use FTS_NOSTAT: fts always sets *fts_statp for a directory.
1086 2006-10-20 Jim Meyering <jim@meyering.net>
1088 * src/od.c (usage): Change description of default to use "-w16",
1089 not the now-invalid "-w 16" syntax. From Dan Jacobson.
1091 2006-10-19 Jim Meyering <jim@meyering.net>
1093 * bootstrap: Add names to each .gitignore file (if it exists)
1094 as well as to .cvsignore.
1096 * Makefile.maint (po-check): This rule didn't detect the new use
1097 of "gettext" (as opposed to the use of "_" everywhere else) in
1098 lib/xstrtol.h. Adjust the grep regexp so that now it does.
1100 2006-10-18 Paul Eggert <eggert@cs.ucla.edu>
1102 * src/copy.c (copy_reg): Rewrite slightly to avoid duplicate code
1103 when opening dst_name.
1104 (copy_reg, copy_internal): Use (SYSCALL != 0) rather than plain
1105 (SYSCALL) to test for failure in a system call.
1107 * src/copy.c (copy_internal): Use mknod rather than mkfifo to copy
1108 a fifo. This preserves the special mode bits on Solaris 10, which
1109 is compatible with what Solaris 10 cp -R does.
1111 * src/copy.c (copy_internal): Remove redundant and confusing local
1114 * src/copy.c (copy_internal): Don't pass mkdir a mode greater than
1115 7777. This matches historical 'cp' behavior and avoids some
1116 (though not all) implementation-defined behavior of mkdir.
1117 * src/cp.c (make_dir_parents_private): Likewise.
1118 * src/copy.c (copy_internal): Don't pass 'open' a mode greater
1119 than 777. This is required by POSIX. It doesn't make any difference
1120 in actual behavior on any host that I know of.
1122 2006-10-17 Jim Meyering <jim@meyering.net>
1124 * src/dd.c (usage): Use two spaces (not one) to separate the
1125 "fdatasync" option string from its description, so help2man formats
1126 the derived man page properly. Reported by Samuel Thibault
1127 in <http://bugs.debian.org/393649>.
1129 2006-10-16 Jim Meyering <jim@meyering.net>
1131 * .x-sc_trailing_blank: Remove names of files that are no longer
1134 2006-10-16 Paul Eggert <eggert@cs.ucla.edu>
1136 * src/groups.sh (version): Reword message to match the other programs.
1137 Problem reported by Eric Blake.
1139 2006-10-14 Jim Meyering <jim@meyering.net>
1141 * Makefile.maint (headers_with_interesting_macro_defs): Define.
1142 (.re-defmac, sc_always_defined_macros): New rules.
1144 * src/system.h (EXIT_FAILURE, EXIT_SUCCESS): Remove definitions.
1145 Instead, include "exit.h". This hereby retires the work-around for
1146 "Sony NEWS-OS Release 4.0C"'s bug due to "#define EXIT_FAILURE 0".
1148 * src/cksum.c (uint_fast32_t): Don't define.
1149 Instead, include <stdint.h>.
1151 * src/pinky.c (S_IWGRP): Don't define.
1152 It's already defined by "stat-macros.h" (included via system.h).
1154 * Makefile.cfg: Remove cruft that's now handled via bootstrap.
1155 * Makefile.maint: Likewise, remove these targets/rules/variables:
1156 (local_updates, update, cvs-update, wget_files, get-targets): Remove.
1157 (cvs_files, wget-update, automake_repo): Likewise.
1158 Move the comment about cvsu to build-aux/vc-list-files,
1159 where cvsu is actually used.
1161 * Makefile.maint (cvs-update): Use $(CVS), not "cvs".
1163 Work also when the working directory (with e.g. coreutils sources)
1164 is version controlled with git, rather than CVS.
1165 * bootstrap (CVS_only_file): Test for the existence of README-cvs,
1167 In messages and comments, say e.g., "checked-out sources",
1168 rather than "CVS sources".
1169 (version_controlled_file): New function. Work for git as well as
1170 for CVS. Don't use grep's -q option.
1171 (slurp): Call it here, in place of CVS-specific code.
1173 * NEWS: cp -r --backup dir1 dir2, would rename an existing dir1/dir2
1175 * src/copy.c (copy_internal): Although we do create a backup of each
1176 destination directory when in move mode, don't do that when copying.
1177 Reported by Peter Breitenlohner, in
1178 <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/8616>.
1179 * tests/cp/backup-dir: New file. Test for the above.
1180 * tests/cp/Makefile.am (TESTS): Add backup-dir.
1182 2006-10-13 Jim Meyering <jim@meyering.net>
1184 More chown/chgrp dereferencing-related fixes.
1185 * src/chown-core.c (change_file_owner): Don't use fts_statp if
1186 we're dereferencing symlinks.
1187 Reverse conjuncts, so that we use dereference file_stats
1188 (aka ent->fts_statp) only *after* we've confirmed that
1189 chopt->affect_symlink_referent is true. Otherwise, we might
1190 use ent->fts_statp uninitialized.
1191 Don't turn on FTS_NOSTAT when dereferencing symlinks.
1192 * tests/chown/deref: Update the expected diagnostic, now that
1193 this test case (trying to use "chown --dereference ..." on a
1194 dangling symlink) takes a different code path.
1196 2006-10-13 Paul Eggert <eggert@cs.ucla.edu>
1198 Sync from Bison, as follows:
1200 2006-10-01 Paul Eggert <eggert@cs.ucla.edu>
1202 Fix problems with translating English-language diagnostics.
1203 * bootstrap: Fix bug introduced in recent bootstrap changes, with
1204 respect to bison-runtime pot generation. The YY_ stuff
1205 wasn't being captured.
1207 2006-10-13 Jim Meyering <jim@meyering.net>
1209 * src/chown-core.c (change_file_owner): Use fstatat, not stat,
1210 now that we're using fts_open with FTS_CWDFD.
1211 * tests/chgrp/posix-H: Add --preserve-root to an invocation of
1212 chgrp, to exercise the above fix.
1213 * NEWS: Mention the above.
1215 * src/du-tests: Clean up a little, though it's still not portable.
1217 * .vg-suppressions: Add 3 more for debian unstable.
1219 * tests/ls/Test.pm: Remove long-unused file.
1220 * Makefile.am (EXTRA_DIST): Add bootstrap.conf.
1221 Suggestions from Bruno Haible.
1223 2006-10-12 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1225 * Makefile.am (THANKS-to-translators): Add missing $(srcdir).
1226 (MAINTAINERCLEANFILES): Add .kludge-stamp.
1227 * man/Makefile.am (MAINTAINERCLEANFILES): Typo $(dist_man_MANS)
1228 instead of $(man_MANS).
1230 2006-10-12 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
1232 * configure.ac: Avoid compiler warnings about default return
1233 type in function definitions and unused variables in tests.
1234 * src/who.c (print_user) [HAVE_UT_HOST]: hostlen is only needed
1235 if this is #defined.
1237 2006-10-12 Jim Meyering <jim@meyering.net>
1239 * configure.ac: Reflect s/gl_MACROS/coreutils_MACROS/ renaming.
1240 Call gl_INIT directly, rather than through the above.
1242 2006-10-11 Paul Eggert <eggert@cs.ucla.edu>
1244 * bootstrap (symlink_to_gnulib): Fix bug: the dot_dots shell
1245 variable was sometimes used without being initialized. This
1246 messed up the installation of the INSTALL file in some cases.
1248 2006-10-11 Jim Meyering <jim@meyering.net>
1250 * src/ls.c (usage): Correct description of -s, --size.
1251 It works even without -l. Suggestion from Karl Berry.
1253 2006-10-10 Paul Eggert <eggert@cs.ucla.edu>
1255 * src/ls.c (quote_name): Use initializer rather than memset to
1256 initialize an object to zero. This is easier to read and is less
1257 likely to introduce a runtime error due to a mixup. It causes
1258 gcc -W to issue a warning, but you can work around this by
1259 appending -Wno-missing-field-initializers.
1260 * src/pathchk.c (portable_chars_only): Likewise.
1261 * src/shred.c (main): Likewise.
1262 * src/stty.c (main): Likewise.
1263 * src/tr.c (card_of_complement): Likewise.
1264 * src/wc.c (wc): Likewise.
1266 2006-10-09 Paul Eggert <eggert@cs.ucla.edu>
1268 * src/sort.c (usage): Mention again that sort fields are origin 1.
1270 * NEWS: Fix typo: iso-8602 -> iso-8601. Problem reported by
1273 * bootstrap (usage, main program, symlink_to_gnulib): Add option
1274 --copy. Inspired by a suggestion from Bruno Haible.
1276 2006-10-09 Jim Meyering <jim@meyering.net>
1278 Avoid a compiler warning.
1279 * src/pathchk.c (portable_chars_only): Initialize variable of type
1280 mbstate_t via memset, rather than via '{0}'. Patch from Bruno Haible.
1282 2006-10-06 Paul Eggert <eggert@cs.ucla.edu>
1284 Fix bug reported today by Mike Frysinger: mkdir -pv is logging the
1285 wrong file name in some cases. Lars Wendler reported a bug in
1287 * src/install.c (make_ancestor): New arg COMPONENT.
1288 * src/mkdir.c (make_ancestor): Likewise.
1289 * tests/install/basic-1: Check for install -Dv bug.
1290 * tests/mkdir/Makefile.am (TESTS): Add p-v.
1291 * tests/mkdir/p-v: New file, to test this bug.
1293 2006-10-05 Paul Eggert <eggert@cs.ucla.edu>
1295 * src/chgrp.c: Don't include lchown.h; no longer needed.
1296 * src/chown.c: Likewise.
1298 * tests/ls/stat-dtype: Use a dynamic test to decide whether the
1299 current file system has useful d_type info.
1301 * src/dd.c (flags): noatime and nofollow now depend on
1302 HAVE_WORKING_O_NOATIME and HAVE_WORKING_O_NOFOLLOW, too.
1303 (usage): Output info about noatime and nofollow only if
1304 they are known to work.
1305 * src/remove.c (AD_push): Inspect HAVE_WORKING_O_NOFOLLOW rather
1306 than O_NOFOLLOW, when testing whether it's possible to avoid a
1307 race condition reliably.
1309 2006-10-05 Jim Meyering <jim@meyering.net>
1311 * src/c99-to-c89.diff: Update to reflect new offsets.
1313 * tests/install/basic-1: Skip the latter part of this test if the
1314 just-built dd binary is not readable. Otherwise, this test would fail
1315 when binaries were created as root. Reported by Bauke Jan Douma in
1316 <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/8433>.
1318 2006-10-03 Paul Eggert <eggert@cs.ucla.edu>
1320 * src/system.h (ST_BLKSIZE): Ceiling at SIZE_MAX / 8 + 1, not at 4
1321 MiB, since XFS hosts can legitimately have large values of
1322 st_blksize. Problem reported by Tony Ernst in
1323 <http://savannah.gnu.org/bugs/?17903>.
1325 2006-10-04 Jim Meyering <jim@meyering.net>
1327 * src/remove.c (nonexistent_file_errno): Remove ENAMETOOLONG.
1328 Paul Eggert pointed out that the specified file may exist,
1329 in spite of such an errno value.
1330 * tests/rm/Makefile.am (TESTS): Remove ignore-name-too-long.
1331 * tests/rm/ignore-name-too-long: Remove file.
1332 * NEWS: Update here, too.
1334 2006-10-03 Jim Meyering <jim@meyering.net>
1336 * tests/rm/fail-eperm: Report failure also if rm is terminated by
1339 * src/c99-to-c89.diff: Convert two c99'isms -- one in remove.c
1340 and one in shred.c -- that were added before coreutils-6.3.
1341 Reported by Michael Deutschmann.
1343 * src/c99-to-c89.diff: Update to reflect new offsets.
1345 * src/remove.c (remove_entry): With -f, exit successfully in spite
1346 of a missing file under some very unusual conditions (with errno
1347 being any of ENOENT, ENOTDIR, ENAMETOOLONG).
1349 With --force (-f), rm no longer fails for ENOTDIR.
1350 * src/remove.c (ignorable_missing): New function.
1351 Use it everywhere, rather than open-coding the test.
1352 Andreas Schwab reported the ENOTDIR problem.
1353 (ignorable_missing): Similarly, don't fail for ENAMETOOLONG.
1355 * NEWS: Mention the bug fix.
1356 * tests/rm/ignorable: New file. Test for the ENOTDIR case.
1357 * tests/rm/ignore-name-too-long: New file. Test for ENAMETOOLONG.
1358 * tests/rm/Makefile.am (TESTS): Add the new file names.
1360 * bootstrap: Undo last change to this file, since now gnulib-tool
1361 sticks with the automake default in generating dependencies.
1363 * NEWS: Add a line for 6.4-cvs.
1364 * configure.ac (AC_INIT): Bump to 6.4 and add "-cvs" suffix.
1366 2006-09-30 Jim Meyering <jim@meyering.net>
1369 * NEWS: Record the 6.3 release date.
1370 * configure.ac (AC_INIT): Remove "-cvs" suffix from version string.
1372 * NEWS: Mention Paul's Solaris 8 vs. 10 work-around.
1374 * src/c99-to-c89.diff: Update offsets.
1376 2006-09-29 Paul Eggert <eggert@cs.ucla.edu>
1378 * tests/rm/readdir-bug: Don't use $(...) in a shell script,
1379 as it doesn't work with Solaris /bin/sh.
1381 2006-09-29 Jim Meyering <jim@meyering.net>
1383 * NEWS: Mention Paul's fix (to gnulib's canon-host.c) for
1386 * tests/seq/basic [neg-2, eq-wid-2]: Comment out tests that
1387 use .1 as the increment. Actual output varies too much.
1388 [eq-wid-3]: New, commented out test.
1390 * src/shuf.c (read_input): Fix an off-by-one error that
1391 would cause an infloop for piped input of 8KB or more.
1392 * NEWS: Mention the fix.
1393 * tests/misc/shuf: Test for the above fix.
1395 Since any system may be affected by the Darwin readdir bug,
1396 perform the extra rewinddir unconditionally. The performance
1397 impact of rewinding a directory is negligible.
1398 * src/remove.c (NEED_REWIND): Define to use
1399 CONSECUTIVE_READDIR_UNLINK_THRESHOLD unconditionally.
1401 * tests/seq/basic: Use .11 as the upper bound, in case the ".1"
1402 increment translates to a slightly larger value.
1403 This corrects a test failure on FreeBSD 6.1 reported by Nelson Beebe.
1404 The final expected value wasn't being printed.
1406 Work around a readdir bug in Darwin 7.9.0 (MacOS X 10.3.9) on HFS+
1407 and NFS, whereby rm would not remove all files in a directory.
1408 * src/remove.c (CONSECUTIVE_READDIR_UNLINK_THRESHOLD): Reduce to 10.
1409 (NEED_REWIND): New macro, so that we incur the cost of the work-around
1410 rewinddir only on afflicted systems.
1411 * NEWS: Clarify and correct.
1412 * tests/rm/readdir-bug: New file. Test for the above fix.
1413 * tests/rm/Makefile.am (TESTS): Add it.
1414 Prompted by testing and analysis from Bruno Haible:
1415 http://lists.gnu.org/archive/html/bug-coreutils/2006-09/msg00326.html
1417 2006-09-28 Paul Eggert <eggert@cs.ucla.edu>
1419 * tests/rm/fail-eperm: Unset BASH_ENV, CDPATH, and ENV, too;
1420 suggested for Debian stable, which uses Perl 5.8.4.
1422 2006-09-28 Jim Meyering <jim@meyering.net>
1424 Automatically generated dependencies are important even
1425 when all of the sources in a directory come from gnulib.
1426 * bootstrap (gnulib_tool): Remove the "no-dependencies" automake
1427 option that gnulib-tool adds to what becomes our lib/gnulib.mk.
1429 * tests/rm/fail-eperm: Enable Perl's (-T) taint checking.
1430 Ensure that IFS is set properly and unset PATH.
1432 Work properly even when the name of the selected file starts with "-".
1433 Invoke rm via "../../src/rm", and adjust expected output.
1434 Prompted by a patch from Tim Waugh.
1436 * README-cvs: Add Bison to the list of required packages.
1438 2006-09-26 Jim Meyering <jim@meyering.net>
1440 * src/c99-to-c89.diff: Update offsets.
1442 * NEWS: rm works around a bug in Darwin 8.6.1 w/NFS that kept
1443 it from removing a directory containing 188 or more entries.
1444 * src/remove.c (CONSECUTIVE_READDIR_UNLINK_THRESHOLD): Decrease by
1445 20, go work around the buggy readdir on Darwin 8.6.1 with NFS.
1446 Reported by Matthew Woehlke.
1448 2006-09-26 Paul Eggert <eggert@cs.ucla.edu>
1450 * NEWS: "groups user" no longer outputs "user :"; you need at least
1451 two users. "groups" now processes options like --help more compatibly.
1452 * src/groups.sh: Implement the option-processing change.
1453 Handle user and group names with special characters more robustly.
1454 Report write errors instead of exiting silently with status 1.
1456 2006-09-26 Jim Meyering <jim@meyering.net>
1458 * README: Warn not to run autoreconf manually. Use bootstrap instead.
1460 * src/groups.sh: When invoked with 0 or 1 argument, just exec "id".
1461 Rewrite to avoid using temporary, $status.
1463 * NEWS: Mention the bug fix.
1464 * src/groups.sh: Don't hide a write failure.
1465 Reported by Iain Calder <ic56@rogers.com>.
1467 2006-09-25 Jim Meyering <jim@meyering.net>
1469 * src/chown.c (usage): Clarify --dereference description.
1470 * src/chgrp.c (usage): Likewise. Suggestion from Jamie McClelland.
1472 2006-09-24 Jim Meyering <jim@meyering.net>
1474 * NEWS: Mention these fixes.
1475 * src/copy.c (copy_reg): With --verbose (-v), print
1476 "removed `file_name'" just after unlinking a file.
1477 (copy_internal): Likewise, in three more places.
1478 Marc Lehman reported that "touch x; ln x y; mv -v x y" was silent.
1479 * tests/mv/hard-verbose: New file. Test for the above fix.
1480 * tests/mv/Makefile.am (TESTS): Add hard-verbose.
1482 * tests/help-version (sync_args): Don't call sync, since it spins up
1483 disks that I've deliberately caused to spin down (but not unmounted).
1485 * NEWS: Mention the improvement to sort.
1487 * tests/tail-2/proc-ksyms: Require that /proc/ksyms be readable
1488 as well as existing.
1490 * tests/ls/stat-dtype: Don't use tmpfs on linux-2.4 or older,
1491 since that predated addition of d_type support.
1493 2006-09-23 Jim Meyering <jim@meyering.net>
1495 * gl/modules/getloadavg.diff: New file. Work around the way the latest
1496 version of the getloadavg module interacts with our bootstrap script.
1497 * bootstrap (gnulib_tool_options): Add "--local-dir gl".
1498 * Makefile.am (EXTRA_DIST): Sort file names.
1499 Add bootstrap and gl/modules/getloadavg.diff
1501 2006-09-20 Paul Eggert <eggert@cs.ucla.edu>
1503 * bootstrap: Add support for --force.
1504 (usage): New function. Describe usage less tersely.
1505 (CVS_only_file): New var.
1507 * NEWS: Document fix for cp -i and mv -i.
1508 * src/copy.c (copy_internal): With -i, prompt even if the source
1509 is a directory and the destination is not. This is required by
1510 POSIX and gives the user a chance to bail out before failing.
1511 * tests/cp/Makefile.am (TESTS): Add cp-i.
1512 * tests/cp/cp-i: New file.
1513 * tests/mv/Makefile.am (TESTS): Add i-5.
1514 * tests/mv/i-5: New file.
1516 2006-09-20 Jim Meyering <jim@meyering.net>
1518 * NEWS: Mention the chmod bug fix.
1520 * tests/chmod/inaccessible: New test, specifically for this bug.
1521 Based on a test case from Paul Eggert.
1522 * tests/chmod/Makefile.am (TESTS): Add inaccessible.
1524 Fix the 2006-09-18 bug differently.
1525 * src/chmod.c: (process_file): Upon FTS_NS for a top-level file,
1526 tell fts_read to stat the file again, in case it has become
1527 accessible since the initial fts_open call.
1528 * src/chown-core.c (change_file_owner): Likewise.
1530 * src/chmod.c: Revert last change. There is a better way.
1531 * src/chown-core.c: Likewise.
1533 2006-09-19 Paul Eggert <eggert@cs.ucla.edu>
1535 * src/ln.c (target_directory_operand): Rewrite to avoid porting
1536 problem on Tandem reported by Matthew Woehlke in
1537 <https://savannah.gnu.org/bugs/?17172>.
1539 2006-09-18 Paul Eggert <eggert@cs.ucla.edu>
1541 Fix bug where chmod, chown, and chgrp did not process operands
1542 left-to-right in some cases.
1543 * src/chmod.c (wd_errno): New var.
1544 (chmod_file): New function, with most of the contents of the
1545 old prcess_file function.
1546 (process_files): Use it. This gives file names to fts one
1547 at a time, so that they are processed left-to-right as POSIX
1549 * src/chown-core.c (wd_errno, chown_files): Likewise.
1550 (chown_file): New function.
1551 * tests/install/basic-1: Redo test so as to not workaround
1552 the chmod bug, thereby testing for it.
1554 * src/shuf.c (main): Quote the entire range when reporting an
1555 invalid one, rather than just the part that contained the error.
1557 * tests/stty/row-col-1: Rewrite to avoid temporary file that is
1558 sometimes left behind if the test is skipped or interrupted.
1560 * bootstrap (symlink_to_gnulib): New function.
1561 (cp_mark_as_generated): Use it, to prefer symlinks-to-gnulib
1562 to copies-of-gnulib.
1563 (cp_mark_as_generated, slurp, gnulib_files):
1564 Avoid making a copy if it's the same as the old version.
1565 (gnulib_files): Add support for this variable (used by Bison).
1567 * tests/ls/stat-vs-dirent: Fix quoting problem in diagnostic
1568 indicating flaw in kernel. Reword to say that the flaw isn't
1569 serious for coreutils, since the flaw does affect ls -i.
1571 * tests/chgrp/basic: Fix bug in test case exposed by building on
1572 Solaris 8 in a setgid directory. The test case incorrectly
1573 assumed that 'symlink' would be in group $g1.
1575 2006-09-18 Jim Meyering <jim@meyering.net>
1577 * NEWS: Add a line for 6.3-cvs.
1578 * configure.ac (AC_INIT): Bump to 6.3 and add "-cvs" suffix.
1581 * NEWS: Record the 6.2 release date.
1582 * configure.ac (AC_INIT): Remove "-cvs" suffix from version string.
1584 2006-09-17 Jim Meyering <jim@meyering.net>
1586 * tests/chgrp/basic: On an OpenBSD system, rather than failing
1587 due to a known problem, merely warn about it.
1588 Rewrite to avoid testing output of chgrp --verbose and chgrp -c.
1589 Instead, use stat to test file system for desired results, directly.
1590 * tests/chgrp/Makefile.am (TESTS_ENVIRONMENT): Set host_triplet.
1592 * tests/envvar-check: Add more variable names to the list of those
1593 that can affect these programs and tests: _POSIX2_VERSION, COLUMNS,
1594 QUOTING_STYLE, TABSIZE, TERM, TMPDIR.
1596 2006-09-16 Paul Eggert <eggert@cs.ucla.edu>
1598 * NEWS: Document that mkdir -p and install -d now fork on occasion.
1599 * bootstrap.conf (gnulib_modules): Add savewd.
1600 * src/install.c: Include savewd.h.
1601 (process_dir): New function.
1602 (main, install_file_in_file_parents): Use it, along with the new
1603 savewd module, to avoid some race conditions.
1604 * src/mkdir.c: Include savewd.h.
1605 (struct mkdir_options): New members make_ancestor_function, mode,
1607 (make_ancestor): Return 1 if the resulting directory is not readable.
1608 (process_dir): New function.
1609 (main): Use it, along with new savewd module, to avoid some
1610 race conditions. Fill in new slots of struct mkdir_options, so
1611 that callees get the values.
1612 * tests/install/basic-1: Test for coreutils 5.97 bug that was
1613 fixed in coreutils 6.0, and which should still be fixed with
1615 * tests/mkdir/p-3: Likewise.
1617 2006-09-15 Jim Meyering <jim@meyering.net>
1619 * bootstrap.conf (gnulib_modules): Add rename-dest-slash.
1620 The 2006-09-08 changes made it so "mv dir new-name/" would
1621 fail on NetBSD 1.6. This makes it work once again.
1623 2006-09-14 Jim Meyering <jim@meyering.net>
1625 * src/mv.c (main): Remove unnecessary (always-true) test for 2 <= n.
1626 Instead, since it's a little fragile, assert the condition.
1627 (target_directory_operand): Update comment to reflect latest change.
1629 2006-09-12 Paul Eggert <eggert@cs.ucla.edu>
1631 * src/who.c (print_user): Rewrite to avoid warning from
1632 GCC 4.1.1 with -Wall.
1634 2006-09-12 Jim Meyering <jim@meyering.net>
1636 * tests/mv/atomic: Check for specific strace output, rather than
1637 simply nonempty. RHEL AS 4 would fail this test due to strace
1638 generating "[ Process PID=14434 runs in 32 bit mode. ]".
1639 Reported by Nelson Beebe.
1641 2006-09-11 Jim Meyering <jim@meyering.net>
1643 * src/remove.c (remove_dir): Move new cache_stat_init call onto
1645 (rm_1): Move declaration of "st" and new cache_stat_init call
1646 "down" to nearer where they're used.
1647 * src/c99-to-c89.diff: Add another set of curly braces.
1649 2006-09-10 Paul Eggert <eggert@cs.ucla.edu>
1651 * src/expr.c (eval6): Fix buffer overrun, or bad performance, if
1652 substr's last operand is very large. Performance problem reported
1655 2006-09-09 Jim Meyering <jim@meyering.net>
1657 * Makefile.maint (sc_prohibit_jm_in_m4): Don't hang when there
1659 (sc_require_config_h): Skip this test if there are no version-
1660 controlled .c files.
1661 (sc_prohibit_assert_without_use): Likewise.
1663 2006-09-08 Jim Meyering <jim@meyering.net>
1665 * bootstrap: Export CVS_RSH separate from its assignment, to work
1666 even with Solaris 10's /bin/sh. Suggestion from Mark D. Baushke.
1668 2006-09-08 Paul Eggert <eggert@cs.ucla.edu>
1670 * NEWS: tail now ignores the -f option if POSIXLY_CORRECT is set,
1671 no file operand is given, and standard input is any FIFO.
1672 This is in response to Open Group XCU ERN 114.
1673 * src/tail.c (main): Likewise.
1675 2006-09-08 Jim Meyering <jim@meyering.net>
1677 mv and "cp -r" no longer fail when invoked with two arguments
1678 where the first one names a directory and the second name ends in
1679 a slash and doesn't exist. E.g., "mv dir B/", for nonexistent B,
1680 now succeeds, once more. This reverts part of the 2004-06-27
1682 * NEWS: Say the above.
1683 * src/mv.c (target_directory_operand): Don't require (here)
1684 that the target operand "look like" a directory. This change
1685 pushes the test down to the rename syscall level, where a
1686 "mv dir existing-non-dir/" will mistakenly succeed on older systems
1687 that ignore trailing slashes in the rename destination argument.
1688 * src/cp.c (target_directory_operand): Likewise, but for cp.
1689 * tests/mv/trailing-slash: Exercise the above fixes.
1690 * tests/cp/trailing-slash: New file.
1691 * tests/cp/Makefile.am (EXTRA_DIST): Add trailing-slash.
1693 * bootstrap: Use the previously unused variable, $src,
1694 to avoid repeating "$GNULIB_SRCDIR/$file".
1696 * bootstrap (cp_mark_as_generated): Don't use "local", to
1697 accommodate ancient "/bin/sh". Suggested by Ralf Wildenhues.
1698 Rename now-global "$src" and "$dst" to have cp_ prefix.
1699 Safer, and avoids confusion.
1701 * bootstrap (cp_mark_as_generated): New function.
1702 (slurp): Use it to prepend editor hints and a warning that
1703 the file we're copying is generated.
1704 Suggestion from Bruce Korb.
1705 (cp_mark_as_generated): Don't add C-style comments for .l or .y files.
1706 Fix last-minute typo.
1708 2006-09-07 Jim Meyering <jim@meyering.net>
1710 * bootstrap: Revert last change. There are less disruptive ways
1711 to mark these generated files as read-only.
1713 * src/c99-to-c89.diff: Update to have proper offsets.
1715 2006-09-06 Jim Meyering <jim@meyering.net>
1717 Ensure that some gnulib-tool-generated files are read-only.
1718 * bootstrap (slurp): Put the body of this function in a sub-shell,
1719 with "umask a-w" so that all new files are read-only. Remove each
1720 file before we write to it, in case it's read-only.
1721 Make po/Makevars and runtime-po/Makevars read-only, too.
1723 2006-09-05 Jim Meyering <jim@meyering.net>
1725 * tests/cp/acl: Skip this test when cp lacks ACL support.
1726 * tests/cp/Makefile.am (TESTS_ENVIRONMENT): Set $(CONFIG_HEADER).
1728 * src/c99-to-c89.diff (remove.c): Adapt one hunk to match the new
1729 context from change of 2006-09-02.
1731 2006-09-04 Jim Meyering <jim@meyering.net>
1733 * README-cvs: Fix typo in update command.
1735 2006-09-03 Jim Meyering <jim@meyering.net>
1737 * NEWS: Tweak the wording in the new change description so that
1738 no one can think this change causes e.g., `rm -fr foo../' to fail.
1740 * tests/rm/inaccessible: Adjust for movement of config.h to lib/.
1741 Use $CONFIG_HEADER, rather than hard-coding it.
1742 * tests/rm/Makefile.am (TESTS_ENVIRONMENT): Set $CONFIG_HEADER.
1744 2006-09-02 Paul Eggert <eggert@cs.ucla.edu>
1746 * NEWS: rm now rejects attempts to remove /, ./, and ../.
1747 * src/basename.c: Don't include dirname.h, since system.h does it now.
1748 * src/chmod.c: Likewise.
1749 * src/copy.c: Likewise.
1750 * src/cp.c: Likewise.
1751 * src/df.c: Likewise.
1752 * src/dircolors.c: Likewise.
1753 * src/dirname.c: Likewise.
1754 * src/du.c: Likewise.
1755 * src/install.c: Likewise.
1756 * src/ln.c: Likewise.
1757 * src/ls.c: Likewise.
1758 * src/mkdir.c: Likewise.
1759 * src/mv.c: Likewise.
1760 * src/remove.c: Likewise.
1761 * src/rm.c: Likewise.
1762 * src/rmdir.c: Likewise.
1763 * src/shred.c: Likewise.
1764 * src/split.c: Likewise.
1765 * src/su.c: Likewise.
1766 * src/system.h: Include "dirname.h", since dot_or_dotdot needs it
1768 (dot_or_dotdot): Succeed even if "." or ".." is followed by a
1770 * src/rm.c (usage, main): --preserve-root is now the default.
1771 * src/remove.h: Fix comment.
1772 * src/remove.c (cache_fstatat, cache_stat_init): New functions.
1773 (cache_statted, cache_stat_ok): New functions.
1774 (write_protected_non_symlink): Remove struct stat ** buf_p arg,
1775 which is no longer needed with the new functions. All callers
1777 (prompt, is_dir_lstat, remove_entry, remove_dir):
1778 New struct stat * arg. All callers changed.
1779 (write_protected_non_symlink, prompt, is_dir_lstat, remove_entry):
1780 (remove_cwd_entries, remove_dir, rm_1):
1781 Use and maintain the file status cache.
1782 (prompt, remove_entry): Omit the first "directory" in the diagnostic
1783 "Cannot remove directory `foo': is a directory". This causes "rm"
1784 to pass a test case that it would otherwise fail now that it
1785 "knows" more about its argument. I think the diagnostic is better
1786 without the first "directory" anyway.
1787 (prompt): Remove the no-longer-needed IS_DIR arg; all callers changed.
1788 (rm_1): Reject attempts to remove /, ./, or ../.
1789 * tests/rm/Makefile.am (TESTS): Add r-4.
1790 * tests/rm/r-4: New file.
1792 2006-09-01 Paul Eggert <eggert@cs.ucla.edu>
1794 * src/stat.c: Include <stddef.h>
1795 (alignof): New macro.
1796 (HAVE_STRUCT_STATXFS_F_FSID___VAL, HAVE_STRUCT_STATXFS_F_FSID_VAL):
1798 (STRUCT_STATXFS_F_FSID_IS_INTEGER): New macro.
1800 (print_statfs): If f_fsid isn't an integer, grab its words one
1801 at a time in little-endian order. This is a bit easier to configure
1802 and should avoid a compilation failure on MacOS reported by Bruno
1805 2006-08-29 Paul Eggert <eggert@cs.ucla.edu>
1807 * src/stat.c (HAVE_STRUCT_STATXFS_F_FSID_VAL, FSID_VAL): New macros, to
1808 work around a Mac OS X porting problem reported by Bruno Haible in
1809 <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00308.html>.
1810 (print_statfs): Use them.
1812 * bootstrap.conf (gnulib_modules): Add isapipe.
1813 * src/tail.c: Include isapipe.h.
1814 (IS_PIPE_LIKE_FILE_TYPE): Remove.
1815 (IS_TAILABLE_FILE_TYPE): Just list both FIFOs and sockets as
1816 tailable, since this seems to be portable.
1817 (main): Use isapipe, to fix a bug on MacOS X reported by Bruno Haible in
1818 <http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00304.html>.
1820 * src/system.h (LOCALEDIR): Remove, since configmake.h now defines
1823 2006-08-28 Paul Eggert <eggert@cs.ucla.edu>
1825 * src/copy.c (copy_internal): Don't test whether macros like
1826 S_ISLNK are defined, since they're always defined now.
1827 * src/cp.c (main): Likewise.
1828 * src/ln.c (main): Likewise.
1829 * src/ls.c (get_link_name, make_link_name): Likewise.
1830 * src/mknod.c (main): Likewise.
1831 * src/mkfifo.c (usage): Likewise.
1832 * src/who.c (S_IWGRP): Likewise.
1834 Adjust to recent gnulib changes for the gnulib module.
1835 * bootstrap.conf (gnulib_modules): Add fcntl.
1836 * src/system.h (SEEK_SET, SEEK_CUR, SEEK_END): Remove. Other code
1837 is already assuming these macros are defined.
1838 (O_DIRECT, O_DIRECTORY, O_DSYNC, O_NDELAY, O_NOATIME, O_NONBLOCK):
1839 (O_NOCTTY, O_NOFOLLOW, O_NOLINKS, O_RSYNC, O_SYNC, O_BINARY, O_TEXT):
1840 Remove; the fcntl module now handles these.
1842 Adjust to recent gnulib changes for the inttypes module.
1843 * bootstrap.conf (gnulib_modules): Remove stdint; add inttypes.
1844 (excluded_files): Don't exclude m4/inttypes-h.m4 or m4/inttypes-pri.m4.
1846 * src/system.h: Don't bother to include <stdint.h>, since we can
1847 now assume inttypes.h does the equivalent of including stdint.h.
1849 2006-08-27 Jim Meyering <jim@meyering.net>
1851 * src/copy.c (copy_internal): Don't make a backup if the last
1852 component of the source name is "." or "..".
1853 Reported by Andreas Schwab in http://savannah.gnu.org/bugs/?17540.
1854 * NEWS: Mention this.
1855 * tests/cp/src-base-dot: New file. Test for the above fix.
1856 * tests/cp/Makefile.am (TESTS): Add src-base-dot.
1858 * src/system.h (DOT_OR_DOTDOT): Remove macro. Rewrite as a...
1859 (dot_or_dotdot): ...new static inline function.
1860 * src/remove.c (rm_1): Reflect this renaming.
1861 * src/ls.c (basename_is_dot_or_dotdot): Likewise.
1863 * src/copy.c (copy_internal): Add comments.
1865 2006-08-26 Paul Eggert <eggert@cs.ucla.edu>
1867 * src/Makefile.am (AM_CPPFLAGS): Remove -I$(srcdir) and -I../lib,
1868 since Automake supplies them for us. It always did -I$(srcdir),
1869 and with the recent change to AC_CONFIG_HEADERS in configure.ac it
1870 is now also doing -I../lib.
1872 * bootstrap (get_translations): Skip this if WGET_COMMAND is empty.
1873 Fail if the first "echo" fails. Suppress diagnostics from "ls po/*.po"
1874 since there might not be any .po files.
1875 (WGET_COMMAND): Set to empty if wget doesn't
1876 seem to be available.
1878 2006-08-26 Jim Meyering <jim@meyering.net>
1880 This test was failing in some environments.
1881 * tests/ls/color-dtype-dir: Don't rely on eval "`dircolors -b`"
1882 to set LS_COLORS in the environment.
1883 * tests/envvar-check: Instead, ensure that LS_COLORS is not set.
1884 Reported by Bob Proulx.
1886 * src/c99-to-c89.diff: Remove hunk for copy.c; no longer needed.
1888 * Makefile.am (EXTRA_DIST): Remove these files here, too:
1889 .x-sc_no_if_have_config_h, .x-sc_prohibit_assert_without_use,
1890 .x-sc_two_space_separator_in_usage.
1892 Fix "mv --verbose --backup" so its output includes the
1893 " (backup: foo.~1~)" suffix also when backing up a directory.
1894 * NEWS: Report this bug fix.
1895 * src/copy.c (emit_verbose): New function, factored out of...
1896 (copy_internal): ...here. Use the new function.
1897 * tests/mv/backup-dir: Test for the above fix.
1898 * tests/mv/Makefile.am (TESTS): Add backup-dir.
1900 2006-08-25 Paul Eggert <eggert@cs.ucla.edu>
1902 * .x-sc_no_if_have_config_h: Remove; no longer needed.
1903 * .x-sc_prohibit_assert_without_use: Remove; it was empty.
1904 * .x-sc_two_space_separator_in_usage: Likewise.
1905 * Makefile.maint (sc_no_have_config_h): Renamed from
1906 sc_no_if_have_config_h, since it now checks that HAVE_CONFIG_H
1907 is absent everywhere.
1908 * bootstrap.conf (gnulib_modules): Add config-h.
1909 * src/shred.c: Include <config.h> unconditionally, since
1910 we now assume config.h exists.
1911 * src/dircolors.c: Likewise.
1913 2006-08-26 Jim Meyering <jim@meyering.net>
1915 "ls --color" would highlight other-writable and sticky directories
1916 no differently than regular directories on a file system with
1917 dirent.d_type support.
1918 * NEWS: Say the above.
1919 * src/ls.c (gobble_file): With --color, also stat the file when
1920 we know it is a directory.
1921 Derived from an anonymous one-line fix and bug report:
1922 <http://savannah.gnu.org/bugs/?15043>.
1923 * tests/ls/color-dtype-dir: New file. Test for the above fix.
1924 * tests/ls/Makefile.am (TESTS): Add color-dtype-dir.
1926 2006-08-25 Paul Eggert <eggert@cs.ucla.edu>
1928 * .cvsignore: Remove stamp-h1. Add coreutils-*, to ignore
1930 * bootstrap.conf: Add configmake, verify.
1931 * src/.cvsignore: Remove localedir.h.
1932 * src/Makefile.am (localedir, DISTCLEANFILES, localedir.h): Remove;
1933 subsumed by configmake.
1934 * src/system.h: Include configmake.h rather than localedir.h
1935 (LOCALEDIR): New macro.
1937 Rewrite to avoid some unnecessary casts, macros, literals.
1938 * src/shred.c (DEFAULT_PASSES, VERBOSE_UPDATE): Now constants,
1940 (SECTOR_SIZE, SECTOR_MASK): New constants.
1941 (fillpattern, dopass, do_wipefd, main): Remove unnecessary casts,
1942 and use the SECTOR_* constants when applicable. Check for size <
1943 0 rather than size == -1, since negative-size files are a sign of
1946 2006-08-25 Bruno Haible <bruno@clisp.org>
1948 * src/shred.c (dopass): Assume a continuable error if EIO even
1949 if the current position is not a multiple of 512.
1951 2006-08-24 Jim Meyering <jim@meyering.net>
1953 * src/stat.c (print_statfs): Fix typo: remove extra "sizeof".
1955 2006-08-23 Paul Eggert <eggert@cs.ucla.edu>
1957 * src/stat.c (HAVE_STRUCT_STATXFS_F_FSID___VAL): Define. This
1958 macro was being used without being defined.
1959 (SB_F_NAMEMAX): Remove cast.
1960 (f_fsid) [BeOS]: Likewise.
1961 (OUT_NAMEMAX): Renamed from NAMEMAX_FORMAT, with a new meaning.
1963 (out_string, out_int, out_uint, out_uint_o, out_uint_x): New
1965 (xstrcat): Remove. All uses changed to use the above functions.
1966 (print_statfs, print_stat): 2nd arg is now the prefix len, not the
1967 buffer len. All uses changed. Output '?', not '*', for unknown
1968 data or errors. Do not assume signed values can be interchanged
1969 with unsigned when printing.
1970 (print_statfs): For %i, print the fsid as a single int, not as a
1972 (print_it): Quote invalid format better.
1974 * NEWS: printf supports the I flag.
1975 * src/printf.c (print_formatted) [glibc 2.2 or later]: Likewise.
1977 2006-08-23 Bruno Haible <bruno@clisp.org>
1979 * src/stat.c (STRUCT_STATVFS, statfs, f_fsid, f_blocks, f_bfree) [BeOS]:
1980 (f_bavail, f_bsize, STATFS_FRSIZE, f_files, f_ffree) [BeOS]:
1981 (STATXFS_FILE_SYSTEM_TYPE_MEMBER_NAME) [BeOS]: Define.
1983 * src/ls.c (SA_RESTART): Fallback define.
1985 2006-08-23 Paul Eggert <eggert@cs.ucla.edu>
1987 * src/system.h (EDQUOT): Define if not already defined.
1988 Problem reported by Bruno Haible for BeOS.
1990 * .cvsignore: Remove config.h, config.hin, as they are now
1992 * configure.ac (AC_CONFIG_HEADERS): Move config.h and config.hin
1994 * src/Makefile.am (AM_CPPFLAGS): Remove '-I..'; no longer needed.
1996 * bootstrap (slurp): Define gl_LOCK_EARLY instead of gl_LOCK,
1997 to accommodate today's gnulib change.
1999 2006-08-23 Jim Meyering <jim@meyering.net>
2001 * NEWS: Mention the sweeping infrastructure changes.
2003 2006-08-22 Paul Eggert <eggert@cs.ucla.edu>
2005 * bootstrap.conf (gnulib_modules): Add gnupload.
2006 * Makefile.maint (emit_upload_commands): gnupload is now
2008 * gnupload: Remove from CVS, since it's now a gnulib module.
2010 * bootstrap (bootstrap_conf_cleanup): Remove.
2011 (excluded_files): New var.
2012 * bootstrap.conf: Likewise.
2013 * bootstrap (slurp): Exclude files early if they're in the
2014 excluded_files list. That way, their names don't get put into
2017 * aclocal.m4, config.hin, configure:
2018 Remove from CVS, since ./bootstrap generates them automatically.
2019 * .cvsignore: Add INSTALL, Makefile.in, aclocal.m4, config.hin,
2020 configure, *.cache, *.lineno, *.log.
2021 Remove more-specific entries. This catches files like configure.lineno.
2022 * man/.cvsignore: Add Makefile.in.
2023 * src/.cvsignore: Add Makefile.in.
2024 Remove .version, dir.c, install, mvdir, stamp-v, vdir.c, version.c.
2027 * tests/chgrp/.cvsignore:
2028 * tests/chmod/.cvsignore:
2029 * tests/chown/.cvsignore:
2030 * tests/cp/.cvsignore:
2031 * tests/cut/.cvsignore:
2032 * tests/dd/.cvsignore:
2033 * tests/dircolors/.cvsignore:
2034 * tests/du/.cvsignore:
2035 * tests/expr/.cvsignore:
2036 * tests/factor/.cvsignore:
2037 * tests/fmt/.cvsignore:
2038 * tests/head/.cvsignore:
2039 * tests/install/.cvsignore:
2040 * tests/join/.cvsignore:
2041 * tests/ln/.cvsignore:
2042 * tests/ls/.cvsignore:
2043 * tests/ls-2/.cvsignore:
2044 * tests/md5sum/.cvsignore:
2045 * tests/misc/.cvsignore:
2046 * tests/mkdir/.cvsignore:
2047 * tests/mv/.cvsignore:
2048 * tests/od/.cvsignore:
2049 * tests/pr/.cvsignore:
2050 * tests/readlink/.cvsignore:
2051 * tests/rm/.cvsignore:
2052 * tests/rmdir/.cvsignore:
2053 * tests/seq/.cvsignore:
2054 * tests/sha1sum/.cvsignore:
2055 * tests/shred/.cvsignore:
2056 * tests/sort/.cvsignore:
2057 * tests/stty/.cvsignore:
2058 * tests/sum/.cvsignore:
2059 * tests/tac/.cvsignore:
2060 * tests/tail/.cvsignore:
2061 * tests/tail-2/.cvsignore:
2062 * tests/tee/.cvsignore:
2063 * tests/test/.cvsignore:
2064 * tests/touch/.cvsignore:
2065 * tests/tr/.cvsignore:
2066 * tests/tsort/.cvsignore:
2067 * tests/unexpand/.cvsignore:
2068 * tests/uniq/.cvsignore:
2069 * tests/wc/.cvsignore:
2070 Add Makefile.in. Sort entries if necessary. Remove *.I, *.E,
2071 *.X, *.O, *-tests, build-script, mk-script if they're never
2072 created in this directory.
2074 2006-08-22 Bruno Haible <bruno@clisp.org>
2077 * src/uptime.c: Include OS.h if it exists.
2078 (print_uptime): On BeOS, use the get_system_info function (actually a
2079 macro). Loop through utmp entries only if utmp.h or utmpx.h exists.
2080 (uptime): Call read_utmp only if utmp.h or utmpx.h exists.
2082 2006-08-22 Jim Meyering <jim@meyering.net>
2084 * .cvsignore: Add ABOUT-NLS.
2086 Move the check-AUTHORS rule to be run as part of "make distcheck",
2087 rather than "make check".
2088 * src/Makefile.am (check): Don't depend on check-AUTHORS; it would
2089 cause "make check" to fail on systems unable to build all binaries.
2090 * Makefile.maint (check-AUTHORS): New rule.
2091 (local-checks-available): Add it here.
2092 Reported by Bruno Haible. Needed for BeOS.
2094 2006-08-21 Paul Eggert <eggert@cs.ucla.edu>
2096 * src/df.c (print_header, show_dev): Use a column width that
2097 depends on the block size of -P is specified and not autoscaling.
2098 Problem reported by Gustavo G. Rondina in:
2099 http://lists.gnu.org/archive/html/bug-coreutils/2006-08/msg00164.html
2101 2006-08-21 Jim Meyering <jim@meyering.net>
2103 * tests/dircolors/simple (a): Don't fail with an unexpected diagnostic
2104 when the shell variable, SHELL, is not set.
2105 Trigger the failure with "(unset SHELL; make check TESTS=simple)".
2106 Reported by Sven Joachim in <http://bugs.debian.org/355368>.
2108 * src/od.c: Now that HAVE_UNSIGNED_LONG_LONG is no longer defined
2109 in config.h, change the uses to HAVE_UNSIGNED_LONG_LONG_INT.
2110 Otherwise, on a system with 4-byte longs, "od -t u8" fails with this:
2111 od: invalid type string `u8';
2112 this system doesn't provide a 8-byte integral type
2113 FIXME: add a test for this, but skip it when sizeof uintmax < 8.
2115 2006-08-20 Paul Eggert <eggert@cs.ucla.edu>
2117 Add a bootstrap procedure, so that the CVS version contains fewer
2118 files and we bootstrap the rest from gnulib, gettext, etc.
2119 * README-cvs: New file.
2120 * bootstrap: New file.
2121 * bootstrap.conf: New file.
2122 * .x-sc_trailing_blank: Remove config-log, .gdb-history. Add .po.
2123 * configure.ac (AC_PREREQ): Move here from m4/*.m4, for benefit
2125 (gl_DEFAULT_POSIX2_VERSION, gl_USE_SYSTEM_EXTENSIONS, gl_PERL):
2126 (gl_IGNORE_UNUSED_LIBRARIES): Remove; now done by gnulib.
2128 (gl_MACROS): Call just after gl_EARLY, just for clarity.
2129 * src/c99-to-c89.diff: Remove patch to ls.c; no longer needed.
2130 * src/kill.c (strtoimax): Remove decl.
2131 * src/ls.c: Include "wcwidth.h" instead of rolling it ourselves.
2132 * src/wc.c: Likewise.
2133 * src/ls.c (sort_files): Rewrite to avoid need for C99-style
2134 declaration, so that we don't need to patch this file.
2135 * src/printf.c (strtoimax, strtoumax): Remove decls.
2136 * src/su.c: Include getpass.h.
2138 * src/system.h: Include mempcpy.h, stpcpy.h, strpbrk.h.
2139 Include inttypes.h unconditionally.
2140 (LONGEST_MODIFIER, PRIdMAX, PRIoMAX, PRIuMAX, PRIxMAX): Remove.
2141 (stpcpy, strndup, strstr, strtoul, mempcpy, CHAR_MIN, CHAR_MAX):
2142 (SCHAR_MIN, SCHAR_MAX, UCHAR_MAX, SHRT_MIN, SHRT_MAX, INT_MAX):
2143 (INT_MIN, INTMAX_MAX, INTMAX_MIN, UINT_MAX, LONG_MAX, ULONG_MAX):
2144 (SIZE_MAX, SSIZE_MAX, UINTMAX_MAX): Remove.
2146 * ABOUT-NLS, INSTALL, Makefile.in, man/Makefile.in:
2147 * src/Makefile.in, tests/Makefile.in, tests/chgrp/Makefile.in:
2148 * tests/chmod/Makefile.in, tests/chown/Makefile.in:
2149 * tests/cp/Makefile.in, tests/cut/Makefile.in:
2150 * tests/dd/Makefile.in, tests/dircolors/Makefile.in:
2151 * tests/du/Makefile.in, tests/expr/Makefile.in:
2152 * tests/factor/Makefile.in, tests/fmt/Makefile.in:
2153 * tests/general/Makefile.in, tests/head/Makefile.in:
2154 * tests/install/Makefile.in, tests/join/Makefile.in:
2155 * tests/ln/Makefile.in, tests/ls/Makefile.in:
2156 * tests/ls-2/Makefile.in, tests/md5sum/Makefile.in:
2157 * tests/misc/Makefile.in, tests/mkdir/Makefile.in:
2158 * tests/mv/Makefile.in, tests/od/Makefile.in:
2159 * tests/pr/Makefile.in, tests/readlink/Makefile.in:
2160 * tests/rm/Makefile.in, tests/rmdir/Makefile.in:
2161 * tests/seq/Makefile.in, tests/sha1sum/Makefile.in:
2162 * tests/shred/Makefile.in, tests/sort/Makefile.in:
2163 * tests/stty/Makefile.in, tests/sum/Makefile.in:
2164 * tests/tac/Makefile.in, tests/tail/Makefile.in:
2165 * tests/tail-2/Makefile.in, tests/tee/Makefile.in:
2166 * tests/test/Makefile.in, tests/touch/Makefile.in:
2167 * tests/tr/Makefile.in, tests/tsort/Makefile.in:
2168 * tests/unexpand/Makefile.in, tests/uniq/Makefile.in:
2169 * tests/wc/Makefile.in:
2170 Remove from CVS, since ./bootstrap generates them automatically.
2172 2006-08-20 Eric Blake <ebb9@byu.net>
2174 * src/stat.c (USE_STATVFS): Reinstate the patch from 2006-08-15;
2175 the patch from 2006-08-18 broke on cygwin.
2177 2006-08-20 Jim Meyering <jim@meyering.net>
2179 * NEWS: Add a line for 6.2-cvs.
2180 * configure.ac (AC_INIT): Bump to 6.2 and add "-cvs" suffix.
2182 2006-08-19 Jim Meyering <jim@meyering.net>
2185 * NEWS: Record the 6.1 release date.
2186 * configure.ac (AC_INIT): Remove "-cvs" suffix from version string.
2188 * tests/Makefile.am (EXTRA_DIST): Add sparse-file.
2190 Avoid test failure when `make check' is run through debuild.
2191 * tests/help-version: Ensure that $SHELL is set to some value
2192 and exported. Patch from Sven Joachim. For details, see
2193 <http://bugs.debian.org/355368>.
2195 * tests/ls/stat-dtype: Test for the 2006-08-17 `ls -CF' fix.
2197 * README: Describe potential "pre-C99 build failure", and work-around.
2199 Some of my 2006-07-03 changes to tests/*/Makefile.am were being
2200 backed out due to updates provoked by the copyright changes.
2201 * tests/Makefile.am.in (PATH): Prepend $(VG_PATH_PREFIX), so that
2202 it propagates to the derived Makefile.am files.
2203 ($(srcdir)/Makefile.am): Mark generated .am files as read-only,
2204 so we don't mistakenly edit them again.
2205 * tests/cut/Makefile.am: Regenerate.
2206 * tests/head/Makefile.am: Likewise.
2207 * tests/join/Makefile.am: Likewise.
2208 * tests/pr/Makefile.am: Likewise.
2209 * tests/sort/Makefile.am: Likewise.
2210 * tests/tac/Makefile.am: Likewise.
2211 * tests/tail/Makefile.am: Likewise.
2212 * tests/test/Makefile.am: Likewise.
2213 * tests/tr/Makefile.am: Likewise.
2214 * tests/uniq/Makefile.am: Likewise.
2215 * tests/wc/Makefile.am: Likewise.
2217 * NEWS: Fix cp --sparse so that it preserves tail-end sparseness, even
2218 when the file's apparent size is not a multiple of its block size.
2219 * src/copy.c (copy_reg): Don't write a NUL before calling ftruncate.
2220 For some file sizes, writing that single byte would unnecessarily
2221 waste a few file blocks. That write may have been necessary in the
2222 early days of Linux, but now, removing it should be safe.
2223 Based on a patch by Alan Curry: <http://bugs.debian.org/370792>
2224 * tests/cp/sparse: New test for the above.
2225 * tests/cp/Makefile.am (TESTS): Add sparse.
2227 * tests/sparse-file: New file, essence factored out of...
2228 * tests/du/8gb: ... here. Use the new script.
2230 2006-08-18 Paul Eggert <eggert@cs.ucla.edu>
2232 * src/system.h (select_plural): Reduce by 1000000, not 1000, since
2233 the CVS gettext manual now suggests 1000000.
2235 2006-08-18 Bruno Haible <bruno@clisp.org>
2237 Add support for NetBSD 3.0.
2238 * src/stat.c (USE_STATVFS): Set to 1 if 'struct statvfs' has a field
2240 (STATXFS_FILE_SYSTEM_TYPE_MEMBER_NAME): Define also if 'struct statvfs'
2241 has a field f_fstypename.
2242 This undoes the 2006-08-15 to src/stat.c.
2244 2006-08-17 Paul Eggert <eggert@cs.ucla.edu>
2246 Copyright notice fixes.
2248 * COPYING: Upgrade to latest version from FSF.
2250 * src/uname.c: Use (C) in copyright notice.
2252 * .vg-suppressions: Add copyright notice.
2253 * ChangeLog: Likewise.
2254 * ChangeLog-2005: Likewise.
2255 * Makefile.am: Likewise.
2258 * README-valgrind: Likewise.
2260 * announce-gen: Likewise.
2261 * man/Makefile.am: Likewise.
2262 * man/chmod.x: Likewise.
2263 * man/chown.x: Likewise.
2264 * man/df.x: Likewise.
2265 * man/du.x: Likewise.
2266 * man/rm.x: Likewise.
2267 * src/dircolors.hin: Likewise.
2268 * src/du-tests: Likewise.
2269 * src/extract-magic: Likewise.
2270 * src/tac-pipe.c: Likewise.
2271 * src/wheel-gen.pl: Likewise.
2272 * tests/Coreutils.pm: Likewise.
2273 * tests/Makefile.am.in: Likewise.
2274 * tests/acl: Likewise.
2275 * tests/envvar-check: Likewise.
2276 * tests/expensive: Likewise.
2277 * tests/group-names: Likewise.
2278 * tests/help-version: Likewise.
2279 * tests/mk-script: Likewise.
2280 * tests/priv-check: Likewise.
2281 * tests/rwx-to-mode: Likewise.
2282 * tests/sample-test: Likewise.
2283 * tests/setgid-check: Likewise.
2284 * tests/chgrp/basic: Likewise.
2285 * tests/chgrp/deref: Likewise.
2286 * tests/chgrp/no-x: Likewise.
2287 * tests/chgrp/posix-H: Likewise.
2288 * tests/chgrp/recurse: Likewise.
2289 * tests/chmod/c-option: Likewise.
2290 * tests/chmod/equal-x: Likewise.
2291 * tests/chmod/equals: Likewise.
2292 * tests/chmod/no-x: Likewise.
2293 * tests/chmod/octal: Likewise.
2294 * tests/chmod/setgid: Likewise.
2295 * tests/chmod/umask-x: Likewise.
2296 * tests/chmod/usage: Likewise.
2297 * tests/chown/basic: Likewise.
2298 * tests/chown/deref: Likewise.
2299 * tests/chown/separator: Likewise.
2300 * tests/cp/Makefile.am: Likewise.
2301 * tests/cp/acl: Likewise.
2302 * tests/cp/backup-1: Likewise.
2303 * tests/cp/backup-is-src: Likewise.
2304 * tests/cp/cp-HL: Likewise.
2305 * tests/cp/cp-deref: Likewise.
2306 * tests/cp/cp-mv-backup: Likewise.
2307 * tests/cp/cp-parents: Likewise.
2308 * tests/cp/deref-slink: Likewise.
2309 * tests/cp/dir-rm-dest: Likewise.
2310 * tests/cp/dir-slash: Likewise.
2311 * tests/cp/dir-vs-file: Likewise.
2312 * tests/cp/fail-perm: Likewise.
2313 * tests/cp/into-self: Likewise.
2314 * tests/cp/link: Likewise.
2315 * tests/cp/link-no-deref: Likewise.
2316 * tests/cp/link-preserve: Likewise.
2317 * tests/cp/no-deref-link1: Likewise.
2318 * tests/cp/no-deref-link2: Likewise.
2319 * tests/cp/no-deref-link3: Likewise.
2320 * tests/cp/perm: Likewise.
2321 * tests/cp/preserve-2: Likewise.
2322 * tests/cp/r-vs-symlink: Likewise.
2323 * tests/cp/same-file: Likewise.
2324 * tests/cp/slink-2-slink: Likewise.
2325 * tests/cp/special-bits: Likewise.
2326 * tests/cp/symlink-slash: Likewise.
2327 * tests/cut/Makefile.am: Likewise.
2328 * tests/cut/Test.pm: Likewise.
2329 * tests/dd/misc: Likewise.
2330 * tests/dd/not-rewound: Likewise.
2331 * tests/dd/skip-seek: Likewise.
2332 * tests/dd/skip-seek2: Likewise.
2333 * tests/dd/unblock-sync: Likewise.
2334 * tests/dircolors/simple: Likewise.
2335 * tests/du/2g: Likewise.
2336 * tests/du/8gb: Likewise.
2337 * tests/du/Makefile.am: Likewise.
2338 * tests/du/basic: Likewise.
2339 * tests/du/deref: Likewise.
2340 * tests/du/deref-args: Likewise.
2341 * tests/du/exclude: Likewise.
2342 * tests/du/fd-leak: Likewise.
2343 * tests/du/files0-from: Likewise.
2344 * tests/du/hard-link: Likewise.
2345 * tests/du/inaccessible-cwd: Likewise.
2346 * tests/du/long-from-unreadable: Likewise.
2347 * tests/du/long-sloop: Likewise.
2348 * tests/du/no-deref: Likewise.
2349 * tests/du/no-x: Likewise.
2350 * tests/du/restore-wd: Likewise.
2351 * tests/du/slash: Likewise.
2352 * tests/du/slink: Likewise.
2353 * tests/du/trailing-slash: Likewise.
2354 * tests/du/two-args: Likewise.
2355 * tests/expr/basic: Likewise.
2356 * tests/factor/basic: Likewise.
2357 * tests/fmt/basic: Likewise.
2358 * tests/fmt/long-line: Likewise.
2359 * tests/general/Makefile.am: Likewise.
2360 * tests/general/atgeneral.m4: Likewise.
2361 * tests/general/dd.at: Likewise.
2362 * tests/head/Makefile.am: Likewise.
2363 * tests/head/Test.pm: Likewise.
2364 * tests/install/basic-1: Likewise.
2365 * tests/install/create-leading: Likewise.
2366 * tests/install/d-slashdot: Likewise.
2367 * tests/install/trap: Likewise.
2368 * tests/join/Makefile.am: Likewise.
2369 * tests/join/Test.pm: Likewise.
2370 * tests/ln/backup-1: Likewise.
2371 * tests/ln/misc: Likewise.
2372 * tests/ln/sf-1: Likewise.
2373 * tests/ln/target-1: Likewise.
2374 * tests/ls/Makefile.am: Likewise.
2375 * tests/ls/Test.pm: Likewise.
2376 * tests/ls/dangle: Likewise.
2377 * tests/ls/dired: Likewise.
2378 * tests/ls/file-type: Likewise.
2379 * tests/ls/follow-slink: Likewise.
2380 * tests/ls/infloop: Likewise.
2381 * tests/ls/inode: Likewise.
2382 * tests/ls/m-option: Likewise.
2383 * tests/ls/no-arg: Likewise.
2384 * tests/ls/recursive: Likewise.
2385 * tests/ls/rt-1: Likewise.
2386 * tests/ls/stat-dtype: Likewise.
2387 * tests/ls/stat-failed: Likewise.
2388 * tests/ls/stat-vs-dirent: Likewise.
2389 * tests/ls/symlink-slash: Likewise.
2390 * tests/ls/time-1: Likewise.
2391 * tests/ls-2/tests: Likewise.
2392 * tests/md5sum/basic-1: Likewise.
2393 * tests/md5sum/newline-1: Likewise.
2394 * tests/misc/Makefile.am: Likewise.
2395 * tests/misc/base64: Likewise.
2396 * tests/misc/basename: Likewise.
2397 * tests/misc/cat-proc: Likewise.
2398 * tests/misc/close-stdout: Likewise.
2399 * tests/misc/csplit: Likewise.
2400 * tests/misc/date: Likewise.
2401 * tests/misc/date-sec: Likewise.
2402 * tests/misc/df: Likewise.
2403 * tests/misc/dirname: Likewise.
2404 * tests/misc/expand: Likewise.
2405 * tests/misc/false-status: Likewise.
2406 * tests/misc/fold: Likewise.
2407 * tests/misc/head-c: Likewise.
2408 * tests/misc/head-elide-tail: Likewise.
2409 * tests/misc/head-pos: Likewise.
2410 * tests/misc/mknod: Likewise.
2411 * tests/misc/nice: Likewise.
2412 * tests/misc/nl: Likewise.
2413 * tests/misc/nohup: Likewise.
2414 * tests/misc/paste-no-nl: Likewise.
2415 * tests/misc/pathchk1: Likewise.
2416 * tests/misc/printf: Likewise.
2417 * tests/misc/printf-hex: Likewise.
2418 * tests/misc/pwd-long: Likewise.
2419 * tests/misc/sha224sum: Likewise.
2420 * tests/misc/sha256sum: Likewise.
2421 * tests/misc/sha384sum: Likewise.
2422 * tests/misc/sha512sum: Likewise.
2423 * tests/misc/shuf: Likewise.
2424 * tests/misc/sort-merge: Likewise.
2425 * tests/misc/sort-rand: Likewise.
2426 * tests/misc/split-a: Likewise.
2427 * tests/misc/split-fail: Likewise.
2428 * tests/misc/split-l: Likewise.
2429 * tests/misc/stat-fmt: Likewise.
2430 * tests/misc/stat-printf: Likewise.
2431 * tests/misc/tac-continue: Likewise.
2432 * tests/misc/test-diag: Likewise.
2433 * tests/misc/tty-eof: Likewise.
2434 * tests/misc/wc-files0: Likewise.
2435 * tests/misc/wc-files0-from: Likewise.
2436 * tests/mkdir/concurrent-1: Likewise.
2437 * tests/mkdir/p-1: Likewise.
2438 * tests/mkdir/p-2: Likewise.
2439 * tests/mkdir/p-3: Likewise.
2440 * tests/mkdir/p-slashdot: Likewise.
2441 * tests/mkdir/p-thru-slink: Likewise.
2442 * tests/mkdir/parents: Likewise.
2443 * tests/mkdir/perm: Likewise.
2444 * tests/mkdir/special-1: Likewise.
2445 * tests/mkdir/t-slash: Likewise.
2446 * tests/mkdir/writable-under-readonly: Likewise.
2447 * tests/mv/Makefile.am: Likewise.
2448 * tests/mv/acl: Likewise.
2449 * tests/mv/atomic: Likewise.
2450 * tests/mv/backup-is-src: Likewise.
2451 * tests/mv/childproof: Likewise.
2452 * tests/mv/diag: Likewise.
2453 * tests/mv/dir-file: Likewise.
2454 * tests/mv/dir2dir: Likewise.
2455 * tests/mv/dup-source: Likewise.
2456 * tests/mv/force: Likewise.
2457 * tests/mv/hard-2: Likewise.
2458 * tests/mv/hard-3: Likewise.
2459 * tests/mv/hard-4: Likewise.
2460 * tests/mv/hard-link-1: Likewise.
2461 * tests/mv/i-1: Likewise.
2462 * tests/mv/i-2: Likewise.
2463 * tests/mv/i-3: Likewise.
2464 * tests/mv/i-4: Likewise.
2465 * tests/mv/i-link-no: Likewise.
2466 * tests/mv/into-self: Likewise.
2467 * tests/mv/into-self-2: Likewise.
2468 * tests/mv/into-self-3: Likewise.
2469 * tests/mv/into-self-4: Likewise.
2470 * tests/mv/leak-fd: Likewise.
2471 * tests/mv/mv-special-1: Likewise.
2472 * tests/mv/no-target-dir: Likewise.
2473 * tests/mv/part-fail: Likewise.
2474 * tests/mv/part-hardlink: Likewise.
2475 * tests/mv/part-rename: Likewise.
2476 * tests/mv/part-symlink: Likewise.
2477 * tests/mv/partition-perm: Likewise.
2478 * tests/mv/perm-1: Likewise.
2479 * tests/mv/reply-no: Likewise.
2480 * tests/mv/setup: Likewise.
2481 * tests/mv/to-symlink: Likewise.
2482 * tests/mv/trailing-slash: Likewise.
2483 * tests/mv/update: Likewise.
2484 * tests/mv/vfat: Likewise.
2485 * tests/od/od-N: Likewise.
2486 * tests/od/x8: Likewise.
2487 * tests/pr/Makefile.am: Likewise.
2488 * tests/pr/Test.pm: Likewise.
2489 * tests/readlink/can-e: Likewise.
2490 * tests/readlink/can-f: Likewise.
2491 * tests/readlink/can-m: Likewise.
2492 * tests/readlink/rl-1: Likewise.
2493 * tests/rm/Makefile.am: Likewise.
2494 * tests/rm/cycle: Likewise.
2495 * tests/rm/dangling-symlink: Likewise.
2496 * tests/rm/deep-1: Likewise.
2497 * tests/rm/dir-no-w: Likewise.
2498 * tests/rm/dir-nonrecur: Likewise.
2499 * tests/rm/dot-rel: Likewise.
2500 * tests/rm/empty-inacc: Likewise.
2501 * tests/rm/empty-name: Likewise.
2502 * tests/rm/f-1: Likewise.
2503 * tests/rm/fail-2eperm: Likewise.
2504 * tests/rm/fail-eperm: Likewise.
2505 * tests/rm/hash: Likewise.
2506 * tests/rm/i-1: Likewise.
2507 * tests/rm/i-no-r: Likewise.
2508 * tests/rm/inaccessible: Likewise.
2509 * tests/rm/interactive-always: Likewise.
2510 * tests/rm/interactive-once: Likewise.
2511 * tests/rm/ir-1: Likewise.
2512 * tests/rm/isatty: Likewise.
2513 * tests/rm/no-give-up: Likewise.
2514 * tests/rm/r-1: Likewise.
2515 * tests/rm/r-2: Likewise.
2516 * tests/rm/r-3: Likewise.
2517 * tests/rm/rm1: Likewise.
2518 * tests/rm/rm2: Likewise.
2519 * tests/rm/rm3: Likewise.
2520 * tests/rm/rm4: Likewise.
2521 * tests/rm/rm5: Likewise.
2522 * tests/rm/sunos-1: Likewise.
2523 * tests/rm/unread2: Likewise.
2524 * tests/rm/unread3: Likewise.
2525 * tests/rm/unreadable: Likewise.
2526 * tests/rmdir/fail-perm: Likewise.
2527 * tests/rmdir/ignore: Likewise.
2528 * tests/rmdir/t-slash: Likewise.
2529 * tests/seq/basic: Likewise.
2530 * tests/sha1sum/basic-1: Likewise.
2531 * tests/sha1sum/sample-vec: Likewise.
2532 * tests/shred/exact: Likewise.
2533 * tests/shred/remove: Likewise.
2534 * tests/sort/Makefile.am: Likewise.
2535 * tests/sort/Test.pm: Likewise.
2536 * tests/sort-time/Makefile: Likewise.
2537 * tests/sort-time/README: Likewise.
2538 * tests/sort-time/rand-gen: Likewise.
2539 * tests/stty/basic-1: Likewise.
2540 * tests/stty/row-col-1: Likewise.
2541 * tests/sum/basic-1: Likewise.
2542 * tests/sum/sysv: Likewise.
2543 * tests/tac/Makefile.am: Likewise.
2544 * tests/tac/Test.pm: Likewise.
2545 * tests/tail/Makefile.am: Likewise.
2546 * tests/tail/Test.pm: Likewise.
2547 * tests/tail-2/Makefile.am: Likewise.
2548 * tests/tail-2/append-only: Likewise.
2549 * tests/tail-2/assert: Likewise.
2550 * tests/tail-2/assert-2: Likewise.
2551 * tests/tail-2/big-4gb: Likewise.
2552 * tests/tail-2/fflush: Likewise.
2553 * tests/tail-2/infloop-1: Likewise.
2554 * tests/tail-2/proc-ksyms: Likewise.
2555 * tests/tail-2/start-middle: Likewise.
2556 * tests/tail-2/tail-n0f: Likewise.
2557 * tests/tee/basic: Likewise.
2558 * tests/tee/dash: Likewise.
2559 * tests/test/Makefile.am: Likewise.
2560 * tests/test/Test.pm: Likewise.
2561 * tests/touch/Makefile.am: Likewise.
2562 * tests/touch/dangling-symlink: Likewise.
2563 * tests/touch/empty-file: Likewise.
2564 * tests/touch/fail-diag: Likewise.
2565 * tests/touch/fifo: Likewise.
2566 * tests/touch/no-create-missing: Likewise.
2567 * tests/touch/no-rights: Likewise.
2568 * tests/touch/not-owner: Likewise.
2569 * tests/touch/obsolescent: Likewise.
2570 * tests/touch/read-only: Likewise.
2571 * tests/touch/relative: Likewise.
2572 * tests/tr/Makefile.am: Likewise.
2573 * tests/tr/Test.pm: Likewise.
2574 * tests/tr/failures: Likewise.
2575 * tests/tsort/basic-1: Likewise.
2576 * tests/unexpand/basic-1: Likewise.
2577 * tests/uniq/Makefile.am: Likewise.
2578 * tests/uniq/Test.pm: Likewise.
2579 * tests/wc/Makefile.am: Likewise.
2580 * tests/wc/Test.pm: Likewise.
2582 2006-08-17 Jim Meyering <jim@meyering.net>
2584 ls -CF would misalign columns in some cases.
2585 * src/ls.c (get_type_indicator): New function. extracted from...
2586 (print_type_indicator): ...here. Use it.
2587 (length_of_file_name_and_frills): Use it here, too, rather than
2588 assuming stat.st_mode is valid.
2589 Reported by Andreas Schwab, here:
2590 <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/7774>
2591 See the test for this above. FYI, I did ls -CF /proc and visually
2592 inspected the result.
2594 * src/copy.c (copy_internal, same_file_ok): Adjust comments not
2595 to mention the now-removed cp_options.xstat member.
2597 * Makefile.maint (patch-check): Adapt to work now that the patch
2598 modifies more than one file in src/.
2600 With this patch, permit building with Solaris cc on Solaris 7.
2601 * src/c99-to-c89.diff: Add diffs to convert more c99-isms.
2602 This integrates patches from Bruno Haible.
2604 2006-08-16 Paul Eggert <eggert@cs.ucla.edu>
2606 Fix some problems reported by Bruno Haible.
2607 * tests/chmod/setgid (abs_srcdir): Remove; not used or needed.
2608 Skip this test if "chmod g+s d" silently does nothing.
2609 * tests/ls-2/tests: Skip this test suite if we can't set up files
2610 properly for the setuid-etc test. This simplifies some of the
2611 hacks we were using to work around porting problems.
2613 2006-08-16 Jim Meyering <jim@meyering.net>
2615 * tests/cp/Makefile.am: Don't mark "acl" as XFAIL.
2616 * tests/cp/acl: Instead, skip the test if either setfacl
2618 Reported by Michael Stone.
2620 2006-08-16 Paul Eggert <eggert@cs.ucla.edu>
2622 * tests/lang-default (LC_ALL): Set to "C", so we get
2623 English-language diagnostics. Unset the other variables; it
2624 should be portable to use 'unset' for this stuff nowadays.
2625 Problem reported by Bruno Haible. Using "C" reverses the
2626 2000-10-22 change to fileutils in this area.
2628 Fix bugs when printing plurals of numbers that are not
2629 unsigned long int values.
2630 * src/system.h (select_plural): New function.
2631 * src/md5sum.c (digest_check): Use select_plural to avoid bug.
2632 * src/uptime.c (print_uptime): Likewise.
2633 * src/dd.c (print_stats): Likewise. Also, don't use ngettext to
2634 print a floating point number, as reducing to 0 or 1 doesn't work
2635 for some languages. Instead, just use "s" for seconds since it
2636 doesn't need a plural form.
2638 2006-08-16 Bruno Haible <bruno@clisp.org>
2640 Old versions of gzip would write --help output to stderr, and it
2641 would be annoying to see that in the output of every "make" command.
2642 * Makefile.maint (gzip_rsyncable): Throw away stderr output of
2645 2006-08-16 Andreas Schwab <schwab@suse.de>
2647 * tests/cp/acl: Don't use non-portable == operator for test.
2649 2006-08-16 Jim Meyering <jim@meyering.net>
2651 * tests/ls/stat-dtype: Use stat to test file system type, rather
2652 than df -T, in case /etc/mtab lies. Reported by Michael Stone.
2654 2006-08-15 Paul Eggert <eggert@cs.ucla.edu>
2656 * NEWS: Mention that df exits with nonzero status if it generates
2657 no output. This change was in 6.0 but inadvertently unmentioned.
2658 * src/df.c (file_systems_processed): Renamed from n_valid_args, and now
2660 (show_dev): Don't set it until we actually output something.
2661 Print the header if this is the first output.
2662 (main): Don't print a header, as that is now show_dev's job.
2663 * tests/misc/Makefile.am (TESTS): Add df.
2664 * tests/misc/df: New file.
2666 2006-08-15 Eric Blake <ebb9@byu.net>
2668 * src/stat.c (USE_STATVFS): Define to 0 if f_type is needed, but
2669 statvfs.f_type not present. See
2670 <http://savannah.gnu.org/bugs/?func=detailitem&item_id=16325>.
2672 2006-08-15 Paul Eggert <eggert@cs.ucla.edu>
2674 * src/dd.c (print_stats): Don't substitute "1" for number, as this
2675 causes confusion for the Hungarian translators. Problem reported
2676 by Egmont Koblinger here:
2677 http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/7726
2679 2006-08-15 Jim Meyering <jim@meyering.net>
2681 * .x-sc_require_config_h: Add lib/at-func.c.
2683 * NEWS: Add a line for 6.1-cvs.
2684 * configure.ac (AC_INIT): Bump to 6.1 and add "-cvs" suffix.
2686 2006-08-15 Jim Meyering <jim@meyering.net>
2689 * NEWS: Record the 6.0 release date.
2690 * configure.ac (AC_INIT): Remove "-cvs" suffix from version string.
2692 * TODO: Add an item (convert to use gnulib-tool), add to the plan
2693 for id-vs-getgrouplist, and remove a few completed items.
2695 * Makefile.maint (alpha beta major): Fix syntax error.
2697 2006-08-13 Jim Meyering <jim@meyering.net>
2699 * src/shred.c (usage): Don't indent the second line of an item.
2700 Otherwise, help2man would misformat the output.
2701 Reported by Adam Buchbinder in <https://launchpad.net/bugs/48917>.
2703 2006-08-11 Paul Eggert <eggert@cs.ucla.edu>
2705 * configure.ac (AM_GNU_GETTEXT): Upgrade to need-formatstring-macros.
2706 Suggested by Eric Blake to avoid problems like
2707 <http://lists.gnu.org/archive/html/bug-coreutils/2006-07/msg00087.html>.
2709 2006-08-11 Jim Meyering <jim@meyering.net>
2711 * tests/ls/stat-vs-dirent: Too many (losing) systems trigger the
2712 failure that this test checks for (stat/dirent inode mismatch at
2713 a mount point), so continue to give a diagnostic about the failure,
2714 but don't actually count it as a failure.
2716 2006-08-10 Paul Eggert <eggert@cs.ucla.edu>
2718 * ABOUT-NLS: Update from gettext 0.15.
2719 * configure.ac (AM_GNU_GETTEXT_VERSION): Update from 0.13.1 to 0.15.
2721 * src/csplit.c (struct control): Remove fastmap member.
2722 (extract_regexp): Allocate fastmap separately, since otherwise
2723 it might move due to a realloc. This fixes a bug that led
2724 to a core dump on 64-bit sparc Solaris 10 (Sun Studio 10).
2726 2006-08-10 Jim Meyering <jim@meyering.net>
2728 * tests/ls/stat-dtype: If "." is tmpfs, skip this test unless uname -s
2729 reports "Linux". This avoids a failure on Solaris 10's tmpfs.
2730 Redirect both stdout and stderr of df invocations.
2732 * src/dircolors.hin: Add a TERM directive for each of the following:
2733 ansi, color-xterm, gnome, konsole, kterm, rxvt-cygwin,
2734 rxvt-cygwin-native, screen.linux, xterm-256color.
2735 Sort the TERM directives.
2736 From Mike Frysinger.
2738 2006-08-09 Paul Eggert <eggert@cs.ucla.edu>
2740 * src/dd.c (usage): Warn about oflag=append without conv=notrunc.
2741 See Debian bug 373736.
2743 * src/dircolors.hin: Add mlterm, rxvt-unicode; this fixes Debian
2746 * src/.cvsignore: Add shuf.
2748 * Makefile.maint: Remove the po-update procedure; it doesn't
2749 work with the new repository on http://www.iro.umontreal.ca/.
2750 For now I guess we'll have to fix things by hand.
2751 (do-po-update, po-update): Remove. All references removed.
2753 * src/shuf.c (next_line): New function.
2754 (read_input): Use it, to avoid relying on GCC-specific behavior
2755 with void * arithmetic. Problem reported by Bob Proulx.
2756 * Makefile.maint (my-distcheck): Compile with -Wpointer-arith
2757 to detect this sort of problem automatically in the future.
2759 2006-08-09 Jim Meyering <jim@meyering.net>
2761 * src/ls.c: Add a compile-time check to ensure that filetype
2762 and filetype_letter have the same number of elements.
2764 * tests/misc/sort-rand: Remove use of --seed=S.
2766 2006-08-08 Paul Eggert <eggert@cs.ucla.edu>
2768 Add a command 'shuf', and modify shred and sort to use the new
2769 random number generator library of 'shuf'.
2771 * AUTHORS: Add shuf.
2773 * NEWS: Likewise. Mention new --random-source option for shred
2774 and sort. Move "sort +1 -2" notice to the appropriate section,
2775 and clarify its role with respect to POSIXLY_CORRECT.
2776 * man/.cvsignore: Add shuf.1.
2777 * man/Makefile.am (dist_man_MANS): Add shuf.1.
2778 (shuf.1): New dependency.
2779 * man/shuf.x: New file.
2780 * src/Makefile.am (bin_PROGRAMS): Add shuf.
2781 (EXTRA_DIST): Remove rand-isaac.c.
2782 (shuf_LDADD): New macro.
2783 * src/rand-isaac.c: Remove, moving most of its contents to
2785 * src/shuf.c: New file.
2786 * src/shred.c: Use new random-number interface rather than rand-isaac.c.
2787 Don't include rand-isaac.c; include randint.h and randread.h instead.
2788 (RANDOM_SOURCE_OPTION): New enum.
2789 (long_opts, usage, main): New option --random-source.
2790 * src/sort.c: Likewise.
2791 * src/shred.c (struct irand_state, irand_init, irand32, irand_mod): Remove.
2792 All callers changed to use randint interface.
2793 (fillrand): Remove. All callers changed to use randread interface.
2794 (dopass): Remove dependency on ISAAC buffer size.
2795 (genpattern): Don't wipe the random state here.
2796 (randint_source): New static var.
2797 (clear_random_data): New function.
2798 (main): Allocate random source, and arrange to wipe it on exit.
2799 * src/sort.c: Include md5.h, randread.h, xmemxfrm.h.
2800 (longopts, usage, main): Remove undocumented --seed option;
2801 it's now replaced by --random-source.
2802 (rand_state, get_hash): Remove.
2803 (randread_source): New static var.
2804 (random_state, cmp_hashes, compare_random): New functions; they guarantee
2805 no collisions in the random hash function.
2806 (keycompare): Use compare_random for -R; don't fall back on comparing
2807 via memcoll, since compare_random does the right thing.
2808 * tests/misc/Makefile.am (TESTS): Add shuf.
2809 * tests/misc/shuf: New file.
2811 2006-07-29 Paul Eggert <eggert@cs.ucla.edu>
2813 * src/copy.c (set_author): Preserve the st_author field via the
2814 file descriptor dest_desc.
2816 2006-07-28 Paul Eggert <eggert@cs.ucla.edu>
2818 * NEWS: chmod now preserves setuid and setgid bits on directories
2819 if you use a numeric mode with them clear, e.g., "chmod 755 DIR".
2821 Fix test case problems if working directory is setgid,
2822 reported by Bob Proulx.
2823 * tests/cp/fail-perm: Use symbolic mode so that we clear
2824 setgid bit more reliably on directories.
2825 * tests/mkdir/special-1 (set_mode_string): Likewise.
2827 2006-07-27 Jim Meyering <jim@meyering.net>
2829 * src/chgrp.c (usage): Use correct grammar in description of the
2831 * src/chown.c (usage): Likewise.
2833 2006-07-26 Thomas Schwinge <tschwinge@gnu.org> (tiny change)
2835 * src/copy.c (set_author) [HAVE_STRUCT_STAT_ST_AUTHOR]:
2836 Correctly access SRC_SB's element ST_AUTHOR.
2838 2006-07-26 Jim Meyering <jim@meyering.net>
2840 * tests/ls/stat-failed: Adapt to match new expected output.
2843 * src/ls.c (print_color_indicator): Test for S_IFREG first, rather
2844 than having the code test for all of the other types first.
2845 Hoist the set-uid/gid-testing code "up" into this new block.
2846 Classify any other type of file (e.g., S_TYPEISSHM, etc.) as
2847 C_ORPHAN, not as C_FILE.
2849 2006-07-26 Jim Meyering <jim@meyering.net>
2851 Checking in a change from Paul.
2853 2006-07-25 Paul Eggert <eggert@cs.ucla.edu>
2855 * src/ls.c (DT_INIT): Remove. All uses removed.
2856 (enum filetype): Use an ordinary enum rather than trying to keep
2857 the values in sync with DT_FIFO etc. That way, we don't have
2858 to make special assumptions about them. All uses changed.
2859 (whiteout): New constant member of enum filetype.
2860 (filetype_letter): New constant, for use with enum filetype.
2861 (FILETYPE_INDICATORS): New initializer list.
2862 (print_dir): Add case for DT_WHT.
2863 (gobble_file): If stat fails, don't discard information from
2864 readdir; instead, preserve it so it can be printed.
2865 (print_long_format): Fall back on readdir result if stat info
2866 is not available. Use "?" to denote each unknown mode char,
2867 instead of an overall "?", since we now know some of the mode
2869 (print_type_indicator): Now that MODE isn't necessarily
2870 useful, guard all uses.
2871 Now that two blocks in the type-checking tree can set "type = C_FILE",
2872 move the suffix-handling code out and down.
2874 2006-07-26 Jim Meyering <jim@meyering.net>
2876 Prepare for the above change.
2877 * src/ls.c [struct fileinfo] (stat_ok): Rename from stat_failed,
2878 and adjust uses. From a patch by Paul Eggert.
2880 2006-07-26 Jim Meyering <jim@meyering.net>
2882 * src/ls.c: Correct indentation/formatting in a few places.
2884 2006-07-25 Paul Eggert <eggert@cs.ucla.edu>
2886 * tests/cp/fail-perm: Use "chmod 0500" rather than "chmod 500".
2887 Problem report and fix from Bob Proulx.
2888 * NEWS: Clarify the "chmod 0500" news, and correct the vague
2889 statements about compatibility with BSD.
2891 2006-07-25 Jim Meyering <jim@meyering.net>
2893 * src/ls.c (gobble_file): When handling a stat-failed entry,
2894 print the entry name not the absolute_name -- to be consistent
2895 with the usual case.
2896 * tests/ls/stat-failed: Update accordingly.
2898 * src/ls.c: Add parens around the new uses of ?: ternary operator.
2900 * src/dircolors.hin: Mention that ORPHAN refers not just to dangling
2903 Get --dired offsets right when handling stat-failed entries.
2904 * src/ls.c (print_long_format): Be careful to increment P by the
2905 appropriate amount, even when inode_number_width and nlink_width
2907 * tests/ls/stat-failed: Test for the above.
2909 * src/ls.c (gobble_file) [USE_ACL]: Don't use-uninitialized the
2910 have_acl member. That would happen for a directory with both a
2911 non-stat'able entry and one with an ACL.
2913 * src/ls.c (gobble_file): Make it so failure to stat a
2914 non-command-line file provokes an exit status of 1, not 0.
2915 Say "cannot access" rather than "cannot stat".
2916 * tests/ls/stat-failed: New file/test, for the above.
2917 * tests/ls/Makefile.am (TESTS): Add stat-failed.
2918 * tests/ls-2/tests (no-a-isdir-b): Update to reflect addition
2919 of "cannot access " to diagnostic.
2921 * src/ls.c: Declare stat_failed to be "bool", not "int" everywhere.
2923 * src/ls.c [enum filetype] (command_line): Remove member. Not needed.
2924 Replace all occurrences of "type == command_line" with the
2925 equivalent, "command_line_arg".
2927 * src/ls.c: Apply the stat-failed parts of Red Hat's
2928 coreutils-selinux.patch. From Ulrich Drepper.
2929 This makes it so files not mentioned on the command line (e.g.,
2930 names read from a directory that *is* mentioned on the command
2931 line) for which stat fails are still listed. With --color,
2932 such files are colored just like ORPHANs (aka dangling symlinks).
2934 * src/df.c (n_valid_args): Declare global to be static.
2936 2006-07-24 Jim Meyering <jim@meyering.net>
2938 * tests/ls/stat-dtype: Skip this test on reiserfs, since that file
2939 system lacks d_type support.
2941 2006-07-22 Paul Eggert <eggert@cs.ucla.edu>
2943 * man/chmod.x: Update to reflect recent changes to coreutils.texi.
2945 2006-07-21 Jim Meyering <jim@meyering.net>
2947 * src/su.c (usage): Correct typo in --help output: s/commmand/command/
2948 Reported by Tim Waugh.
2949 Also remove the comment duplicating much of --help output.
2951 * src/ls.c (FILE_TYPE_INDICATOR_OPTION): Reposition this new
2952 name so the list remains alphabetized.
2954 Fix another bug: ls --indicator-style=file-type would call
2955 stat for a symlink, even though it wasn't always needed.
2956 In some cases, that unnecessary stat would cause ls to fail.
2957 * src/ls.c (gobble_file): Don't treat symlinks specially (in
2958 requiring a stat syscall). Remove the offending exclusion.
2960 * NEWS: Mention the fix.
2962 * tests/ls/stat-dtype: New file/test, for the above fix.
2963 Also exercises the new df feature, below.
2965 * src/df.c (main): Fail and don't print the headers if no
2966 file system is processed. This makes it easy to test whether
2967 a specified directory is on a file system of a given type or types.
2968 Otherwise, applications would have had to parse df's output.
2969 E.g., is "." either ext3 or reiserfs: df -t ext3 -t reiserfs .
2971 Fix a bug: ls --file-type worked like --indicator-style=slash,
2972 rather than like --indicator-style=file-type.
2973 * src/ls.c (FILE_TYPE_INDICATOR_OPTION): New enum member.
2974 (long_options): Map "file-type" to FILE_TYPE_INDICATOR_OPTION,
2976 (decode_switches): Handle new case: FILE_TYPE_INDICATOR_OPTION.
2977 * NEWS: Mention the fix.
2978 * tests/ls-2/tests (file-type): New test, for the above fix.
2980 2006-07-19 Jim Meyering <jim@meyering.net>
2982 * src/ls.c (print_dir): Give a better diagnostic for failed opendir.
2984 * Makefile.am (EXTRA_DIST): Add build-aux/vc-list-files.
2986 2006-07-16 Paul Eggert <eggert@cs.ucla.edu>
2988 * NEWS: chmod, install, and mkdir now leave setgid and setuid bits
2989 of directories alone unless you specify them explicitly.
2990 install and mkdir now implement X correctly.
2991 install now creates parent directories with mode 755, without
2992 changing their owner or group.
2993 * src/chmod.c (process_file): Adjust to mode_adjust API change.
2994 * src/install.c: Include mkancesdirs.h.
2995 (announce_mkdir, make_ancestor): New functions.
2996 (DEFAULT_MODE): New macro, specifying initial value of 'mode'.
2998 (dir_mode, dir_mode_bits): New vars.
2999 (main): Set dir modes separately from nondir, so that the X
3000 op of -m works correctly.
3001 (main): Remove cwd_errno cruft, since make_dir_parents no longer
3002 affects cwd. Adjust to new make_dir_parents API.
3003 (install_file_in_file_parents): 2nd arg is now char *, not char
3004 const *. Use mkancesdirs instead of rolling our own code.
3005 (change_attributes): Don't worry about AFS, since that kludge
3006 should not be needed any more.
3007 * src/mkdir.c (struct mkdir_options): New struct.
3008 (announce_mkdir, make_ancestor): New functions.
3009 (main): Use them. Adjust to mode_adjust API change. Stick with
3010 umask 0. Use make_dir_parents for all the work.
3011 * src/mkfifo.c (main): Adjust to new mode_adjust API.
3012 * src/mknod.c (main): Likewise.
3013 * tests/chmod/setgid: Do the setgid test instead of bailing.
3014 * tests/mkdir/p-3: Remove re_protect case that no longer applies.
3015 GNU chmod now behaves like other versions of chmod.
3016 * tests/mkdir/perm: Add a test for the X bug.
3018 2006-07-14 Paul Eggert <eggert@cs.ucla.edu>
3020 * src/base64.c (do_decode): Output to parameter OUT, not to stdout.
3021 This doesn't fix any bugs, since OUT always equals stdout, but it
3022 makes the code easier to understand.
3024 2006-07-14 Jim Meyering <jim@meyering.net>
3026 * Makefile.maint (CVS_LIST): Use new file, build-aux/vc-list-files,
3027 rather than open-coding it. Now supports mercurial, too.
3028 * .hgignore: New file.
3029 * Makefile.am (EXTRA_DIST): Add .hgignore, which ignores nearly
3030 all generated files, including ones like configure and po/*.po
3031 that are currently version-controlled in cvs.
3033 * Makefile.am (EXTRA_DIST): Add a few more .??* files.
3034 They've been in CVS, just haven't been distributed before this.
3035 Distribute ChangeLog-2005, too.
3036 (MAINTAINERCLEANFILES): Add THANKS-to-translators.
3038 2006-07-11 Paul Eggert <eggert@cs.ucla.edu>
3040 * src/system.h: Assume <dirent.h> exists, since gnulib assumes
3043 2006-07-09 Jim Meyering <jim@meyering.net>
3045 * tests/mv/dir2dir: Adjust so failing with ENOTEMPTY is ok, too.
3046 That happens with Linux/tmpfs.
3047 * tests/mv/Makefile.am (TESTS): Add dir2dir.
3049 2006-07-09 Paul Eggert <eggert@cs.ucla.edu>
3051 Adjust to recent updates from gnulib.
3052 * src/dd.c (apply_translations): Use toupper rather than
3053 islower followed by toupper; it's simpler and typically
3054 faster now that we assume at least C89 semantics. Similarly
3056 * src/sort.c (inittables): Likewise.
3057 * src/expand.c (expand): Don't assume that isprint etc. return
3058 booleans (needed for pre-C99 hosts).
3059 * src/fmt.c (check_punctuation): Likewise.
3060 * src/ptx.c (initialize_regex, fix_output_parameters): Likewise.
3061 * src/tr.c (is_char_class_member): Likewise.
3062 * src/unexpand.c (unexpand): Likewise.
3063 * src/join.c (is_blank): Remove; no longer needed. All uses
3064 replaced by isblank (to_uchar (...)).
3065 * src/pinky.c (create_fullname): Don't assume char is unsigned.
3066 * src/printf.c (print_esc): Likewise.
3067 * src/ptx.c (SKIP_NON_WHITE, SKIP_WHITE, SKIP_WHITE_BACKWARDS):
3068 (copy_unescaped_string): Likewise.
3069 * src/stat.c (print_it): Likewise.
3070 * src/system.h (_D_EXACT_NAMELEN): Renamed from NLENGTH, for
3071 convenience on GNU systems. All uses changed. Don't bother
3072 looking for any dirent.h substitute other than ndir.h.
3073 (D_INO): Remove unnecessary parentheses.
3074 (IN_CTYPE_DOMAIN, ISGRAPH, ISPRINT, ISALNUM, ISALPHA):
3075 (ISCNTRL, ISLOWER, ISPUNCT, ISSPACE, ISUPPER, ISXDIGIT):
3076 (ISDIGIT_LOCALE, TOLOWER, TOUPPER): Remove. All uses changed
3077 to ctype.h equivalents.
3078 (isblank): Renamed from ISBLANK. Check for HAVE_DECL_ISBLANK too.
3081 2006-07-08 Jim Meyering <jim@meyering.net>
3083 * tests/mv/dir2dir: New file, test for 2006-07-05 fix in copy.c.
3085 * Makefile.maint (sc_the_the): New rule.
3087 * src/dd.c (skip): Remove one of two adjacent "the"s in a comment.
3088 * tests/Coreutils.pm (run_tests): Remove one of two adjacent "then"s
3091 2006-07-07 Jim Meyering <jim@meyering.net>
3093 * NEWS: Mention that mv can now remove an empty destination directory,
3094 and give an example. Prompted by a report from Florent Bayle.
3096 2006-07-05 Jim Meyering <jim@meyering.net>
3098 * src/ls.c (usage): Correct the description of -G: it is useful
3099 only in a long listing. Reported by Martin Pool in
3100 <https://launchpad.net/distros/ubuntu/+source/coreutils/+bug/51653>.
3102 * man/chmod.x: Correct the description of the sticky bit. Reported
3103 by Chris Moore via Ian Jackson in <http://bugs.debian.org/376745>.
3105 * src/copy.c (copy_internal): Don't work around old NFS clients like
3106 SunOS-4.1.4 and Irix 5.3 that set errno to values like EIO and
3107 ENOTEMPTY upon failed rename. Otherwise, we risk misinterpreting
3108 a banal failure as a recursive move-into-self failure.
3109 Reported by Florent Bayle in <http://bugs.debian.org/376749>.
3111 * src/c99-to-c89.diff: Regenerate, to remove fuzz.
3113 2006-07-03 Jim Meyering <jim@meyering.net>
3115 Plug another unusual leak.
3116 (AD_mark_helper): Free malloc'd filename if hash_insert says
3117 that string is already in the hash table.
3119 The dev/inode of the topmost directory in each hierarchy were not
3121 * src/remove.c (remove_cwd_entries): Don't call cycle_check here.
3122 (AD_push): Call it from here instead.
3124 Fix two small leaks.
3125 * src/remove.c (AD_stack_clear): New function.
3127 (AD_pop_and_chdir): Free *prev_dir just before longjmp.
3129 * tests/Makefile.am, tests/*/Makefile.am: (TESTS_ENVIRONMENT):
3130 Add $VG_PATH_PREFIX as a prefix to $PATH
3132 * tests/envvar-check (vars): Add CDPATH and POSIXLY_CORRECT.
3133 * tests/Makefile.am (evar-check): Remove rule.
3134 (EXTRA_DIST): Remove .env-warn.
3135 * tests/.env-warn: Remove file. No longer used.
3136 Suggestion from Eric Blake.
3138 2006-07-02 Paul Eggert <eggert@cs.ucla.edu>
3140 * src/system.h: Include <stdint.h> unconditionally, since we
3141 now assume the stdint module.
3143 2006-07-01 Paul Eggert <eggert@cs.ucla.edu>
3145 * NEWS: With no operand, 'tail -f' now silently ignores the '-f'
3146 only if standard input is a FIFO or pipe and POSIXLY_CORRECT is set.
3147 * src/tail.c (main): Implement this.
3148 * tests/tail/Test.pm (f-pipe-1): Renamed from f-1.
3149 (test_vector): Set POSIXLY_CORRECT for the f-pipe-* tests.
3151 2006-07-01 Jim Meyering <jim@meyering.net>
3153 * src/ln.c (do_link): Use new, shorter URL, for ag-review link.
3155 * .x-sc_require_config_h: Add ^lib/xstrtold\.c$, so make distcheck
3158 2006-06-30 Paul Eggert <eggert@cs.ucla.edu>
3160 * NEWS: seq now uses long double internally rather than double.
3161 It now defaults to a minimal fixed point format if possible.
3162 It lets you use %a, %A, %E, %F, %G.
3163 * src/Makefile.am (seq_LDADD): Remove $(SEQ_LIBM); add $(POW_LIB).
3164 * src/seq.c: Don't include <math.h> or <xstrtol.h>; no longer needed.
3165 (isfinite) [!defined isfinite]: New macro.
3166 (separator, terminator): Now points to const.
3167 (first, step, last): Remove.
3168 (usage): Update to match new behavior.
3169 (struct operand, operand): New type.
3170 (scan_arg): Renamed from scan_double_arg, since we no longer use double.
3172 Compute and return a value of type operand, not double.
3173 (long_double_format): Renamed from valid_format, and now returns a
3174 new format with an "L" added if needed, if the original format was
3175 valid. Allow %a, %A, %E, %F, and %G formats.
3176 (print_numbers): Take numeric values as args rather than from globals.
3177 Print long double, not double.
3178 (get_width_format): Remove.
3179 (get_default_format): New function.
3180 (main): Implement new way of calculating default format.
3181 Don't worry about locale's representation of the decimal point, since
3182 the arguments are always processed in the C locale.
3183 * tests/seq/basic (neg-2): Adjust to new default format.
3184 (eq-wid-1, eq-wid-2): Resurrect these tests, since the new
3185 implementation should do the right thing.
3187 2006-06-30 Jim Meyering <jim@meyering.net>
3189 * tests/stty/basic-1: Work around an intermittent test failure
3190 on HP-UX 11.11. Report and analysis from Bob Proulx.
3191 http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/7475
3193 2006-06-28 Paul Eggert <eggert@cs.ucla.edu>
3195 * NEWS: Support obsolete usages like "sort +1 -2" even when
3196 conforming to POSIX 1003.1-2001, since this is a pure extension to
3197 POSIX. Problem reported by Christian in:
3198 http://lists.gnu.org/archive/html/bug-coreutils/2006-06/msg00220.html
3199 * src/sort.c (main): Implement this.
3201 * src/system.h (CLOSEDIR): Remove. All uses changed to closedir.
3202 Autoconf 2.60 says this stuff was obsolete.
3204 2006-06-28 Jim Meyering <jim@meyering.net>
3206 * src/c99-to-c89.diff: Regenerate, to remove fuzz.
3208 2006-06-28 Bob Proulx <bob@proulx.com> (tiny change)
3210 * tests/mv/i-link-no: Work around HP-UX /bin/sh tracing problem
3211 (set -x when VERBOSE=yes) when stderr is redirected before stdout
3212 causing shell tracing of the stdout redirection to be written to
3213 the stderr file. Avoid problem and test failure on HP-UX by
3214 redirecting stderr last.
3215 * tests/dd/unblock-sync: Order shell file redirections for
3216 stderr and stdout in the common style.
3217 tests/acl: Likewise.
3219 2006-06-27 Jim Meyering <jim@meyering.net>
3221 * tests/misc/cat-proc: Try to avoid any spurious numeric
3222 differences in frequently-changing /proc/cpuinfo.
3223 Reported by Nelson Beebe.
3225 2006-06-26 Jim Meyering <jim@meyering.net>
3227 Attempt rmdir (actually, unlinkat-with-AT_REMOVEDIR) upon any
3228 fd_to_subdirp failure, not just when errno == EACCES.
3229 * src/remove.c (remove_dir): Use unlinkat-with-AT_REMOVEDIR, not
3230 rmdir, here, even though rmdir may happen to be adequate.
3232 * NEWS: rm no longer fails to remove an empty, unreadable directory
3233 * src/remove.c (remove_cwd_entries): If we can't open a directory,
3234 and the failure is not being ignored, try to remove the directory
3235 with rmdir (aka unlinkat-with-AT_REMOVEDIR), in case it's empty.
3236 Problem report and test case from Paul Eggert in
3237 <http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/7425>.
3239 * tests/rm/empty-inacc: New test, for the above.
3241 Avoid a segfault for wc --files0=- < /dev/null.
3242 * src/wc.c (compute_number_width): Return right away if nfiles == 0.
3244 2006-06-25 Jim Meyering <jim@meyering.net>
3246 * NEWS: wc accepts a new option --files0-from=FILE, where FILE
3247 contains a list of NUL-separated file names.
3249 * src/wc.c: Include "readtokens.h".
3250 (usage): Describe the new option, and adjust the `Usage':
3251 with this option, no FILE may be specified on the command line.
3252 (main): Handle the new option.
3253 * tests/misc/wc-files0: New tests, for the above.
3254 * tests/misc/wc-files0-from: Likewise.
3255 * tests/misc/Makefile.am (TESTS): Add wc-files0.
3257 2006-06-24 Jim Meyering <jim@meyering.net>
3259 * src/md5sum.c (DIGEST_BUFFER): Remove now-unused definitions.
3261 2006-06-22 Jim Meyering <jim@meyering.net>
3263 * src/tee.c (tee_files): Rename from tee, to avoid conflict with
3264 the function in glibc's <fcntl.h>. Reported by Andreas Schwab.
3266 2006-06-19 Jim Meyering <jim@meyering.net>
3268 * Makefile.cfg (local-checks-to-skip): Add changelog-check,
3269 so this check is not run as part of "make distcheck".
3271 2006-06-18 Bob Proulx <bob@proulx.com> (tiny change)
3273 * tests/misc/pwd-long: Fix typo (s/neq/ne/) in previous change.
3275 2006-06-18 Jim Meyering <jim@meyering.net>
3277 * tests/misc/pwd-long: Make error output a little clearer.
3279 2006-06-17 Jim Meyering <jim@meyering.net>
3281 * tests/rm/inaccessible: Skip this test on systems without openat
3282 support. Reported by Bob Proulx.
3284 2006-06-15 Bob Proulx <bob@proulx.com> (tiny change)
3286 * tests/misc/mknod: Improve permission checks to handle
3287 running mkdir test in set-gid directories.
3289 2006-06-14 Jim Meyering <jim@meyering.net>
3291 * tests/du/basic: Revamp not to hard-code file system block sizes.
3293 2006-06-12 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
3295 * tests/du/Makefile.am (TESTS_ENVIRONMENT): Pass $(PERL), for
3298 2006-06-11 Jim Meyering <jim@meyering.net>
3300 * .gitignore: New file.
3301 * Makefile.am (EXTRA_DIST): Add .gitignore.
3303 Setting TIME_STYLE=long-iso in the environment would make the
3304 cp/same-file test fail.
3305 * tests/envvar-check (vars): Add TIME_STYLE to the list.
3306 * tests/cp/same-file: Revert last change.
3307 Source the envvar-check script, to ensure that TIME_STYLE
3308 settings don't affect these tests.
3310 2006-06-11 Paul Eggert <eggert@cs.ucla.edu>
3312 * tests/cp/same-file: Execute 'ls' in the C locale, so that it
3313 uses POSIX time stamp formats. Problem reported by John Nixon in
3314 <http://lists.gnu.org/archive/html/bug-coreutils/2006-06/msg00062.html>.
3316 2006-06-10 Jim Meyering <jim@meyering.net>
3318 * NEWS: Mention the AIX-strndup-bug vs. dircolors workaround.
3320 Require a "Version N.M" line at the top of the ChangeLog
3321 file only when making the actual release, not when running
3323 * Makefile.maint (maintainer-distcheck): Don't depend on
3325 (alpha beta major): Depend on it here, instead.
3327 2006-06-08 Jim Meyering <jim@meyering.net>
3329 Ensure that cat works with any of the options, -A -v -e -E -T,
3330 when applied to files in /proc and /sys, even when the FIONREAD
3331 ioctl produces nonsensical results. Before this change, cat would
3332 produce no output (or truncated output), for some linux kernels.
3334 * src/cat.c (write_pending): New function, factored out of cat.
3335 (cat): Also interpret a negative ioctl/FIONREAD count as indicating
3336 that there are bytes to read. Some versions of linux-2.6.16 do that.
3337 Write any pending output before returning.
3338 Reported by Dan Jacobson in <http://bugs.debian.org/370583>.
3339 * NEWS: Mention this bug fix.
3340 * tests/misc/cat-proc: New file. Test for the above.
3341 * tests/misc/Makefile.am (TESTS): Add cat-proc.
3343 2006-06-07 Paul Eggert <eggert@cs.ucla.edu>
3345 * src/expr.c (eval4): Detect overflow properly when multiplying
3348 2006-06-06 Paul Eggert <eggert@cs.ucla.edu>
3350 * NEWS: The 'expr' command now detects and reports integer overflow.
3351 (It would be better to use extended precision instead, but that
3352 would be more work.)
3353 * src/expr.c (integer_overflow): New function.
3354 (eval4, eval3): Check for integer overflow.
3356 2006-06-05 Paul Eggert <eggert@cs.ucla.edu>
3358 Fix problems when building with Solaris/SVR4/etc. make, which uses a
3359 different and somewhat bogus implementation of VPATH. In the
3360 directory tests/misc, rename tests whose names might appear in the
3361 Automake-generated rules. For example, we can't use a test named
3362 'test', since Automake generates a rule that contains the text
3363 "if test -f ./$$tst; ...", and this might expand to something like
3364 "if ../../../coreutils-6.0/tests/misc/test -f ./$$test; ...",
3365 which executes the 'test' script rather than the 'test' command.
3366 * tests/misc/false-status: Renamed from tests/misc/false.
3367 * tests/misc/pwd-long: Renamed from tests/misc/pwd.
3368 * tests/misc/sort-merge: Renamed from tests/misc/sort.
3369 ($prog): Set to 'sort' rather than to $PROG.
3370 * tests/misc/test-diag: Renamed from tests/misc/test.
3371 * tests/misc/Makefile.am (PROG): Take the basename of $$tst,
3372 in case Solaris make has prepended the directory.
3373 (TESTS): Adjust to above renamings.
3374 * tests/misc/expand: Don't assign to PROG; no longer needed
3375 now that Makefile.am sets PROG to the basename.
3376 * tests/misc/fold: Likewise.
3378 2006-06-03 Jim Meyering <jim@meyering.net>
3380 Make `cp --link --no-dereference' work also on systems where the
3381 link system call cannot create a hard link to a symbolic link.
3382 * src/copy.c (copy_internal) [LINK_FOLLOWS_SYMLINKS]: Don't use
3383 the link syscall on a symlink when it would do the wrong thing.
3384 Based on the patch by Aurelien Jarno: <http://bugs.debian.org/329451>
3385 * tests/cp/link-no-deref: New file/test for the above.
3386 * tests/cp/Makefile.am (TESTS): Add link-no-deref.
3387 * NEWS: Mention the change (doesn't affect Linux).
3389 2006-06-01 Paul Eggert <eggert@cs.ucla.edu>
3391 Fix some porting problems in the test cases reported by
3392 Ralf Wildenhues for HP-UX 11.23 in:
3393 http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00238.html
3394 * tests/help-version: Don't assume that \< \> works in sed.
3395 * tests/misc/close-stdout: Don't assume that >&- works.
3396 Add a /dev/full test.
3397 * tests/touch/no-create-missing: Don't assume that >&- works.
3399 2006-05-30 Jim Meyering <jim@meyering.net>
3401 * src/ls.c (usage): Add `v' to the list of sorting-related options.
3404 2006-05-28 Ralf Wildenhues <Ralf.Wildenhues@gmx.de>
3406 * tests/cp/fail-perm: source lang-default.
3407 * tests/rm/inaccessible: Likewise.
3409 2006-05-28 Jim Meyering <jim@meyering.net>
3411 * tests/rm/inaccessible: AIX 4.3.3 gives a different diagnostic.
3412 Recognize it, too. Reported by Ralf Wildenhues, in
3413 http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00192.html
3415 2006-05-27 Jim Meyering <jim@meyering.net>
3417 * src/chgrp.c: Support new options: --preserve-root and
3418 --no-preserve-root. Somehow this program was skipped when those
3419 options were added to chown, chmod, and rm. Reported by
3420 vaqflabuopac@spammotel.com in <http://bugs.debian.org/365656>.
3421 * NEWS: Mention this.
3423 2006-05-25 Paul Eggert <eggert@cs.ucla.edu>
3425 * NEWS: Remove mention of --seed. We'll replace it with something
3426 better, and don't want to indicate that it is supported.
3427 * src/sort.c (usage): Likewise.
3429 2006-05-20 Jim Meyering <jim@meyering.net>
3431 * src/chmod.c (main): Use FTS_PHYSICAL here, too.
3433 * src/du.c (main): Rename local, s/symlink_deref_bit/symlink_deref_bits/
3434 and arrange for -D to set fts' FTS_PHYSICAL bit as well as
3435 FTS_COMFOLLOW. Spotted by Justin Pryzby.
3437 * gnupload: Merge changes from automake, retaining the ""--to...
3438 kludge to placate overzealous `make distcheck' check.
3440 2006-05-19 Jim Meyering <jim@meyering.net>
3442 * src/du.c (main): Don't let -D, -L, or -P turn off the internal
3443 FTS_TIGHT_CYCLE_CHECK directory traversal option.
3444 Reported by Justin Pryzby in http://bugs.debian.org/367691
3446 2006-05-15 Jim Meyering <jim@meyering.net>
3448 * src/cp.c (usage): Correct description of -a: s/-dpR/-dpPR/.
3449 From Tomas Pospisek.
3451 2006-05-13 Jim Meyering <jim@meyering.net>
3453 * tests/mv/no-target-dir: Test two more cases.
3455 2006-05-11 Jim Meyering <jim@meyering.net>
3457 mv -T DIR EMPTY_DIR no longer fails unconditionally
3458 * src/copy.c (copy_internal): Don't manually prohibit a move where
3459 the destination is an existing directory. Sometimes doing that is
3460 valid. Let the rename system call enforce the rules. That is
3461 allowed only when the source is a directory and the destination
3462 directory (to be replaced) is empty. Reported by Eric Blake.
3463 * tests/mv/no-target-dir: New file/test for this.
3464 * tests/mv/Makefile.am (TESTS): Add no-target-dir.
3465 * NEWS: Mention this.
3467 * tests/mv/atomic: New file/test for yesterday's fix.
3468 * tests/mv/Makefile.am (TESTS): Add atomic.
3470 * tests/du/long-sloop: Avoid harmless `ambiguous redirect' diagnostic.
3472 2006-05-10 Jim Meyering <jim@meyering.net>
3474 * src/copy.c (copy_internal): Don't explicitly unlink the destination
3475 when moving a symlink into the place of an existing non-directory.
3476 Reported by Joshua Hudson.
3477 * NEWS: mention this.
3479 2006-05-07 Jim Meyering <jim@meyering.net>
3481 * Makefile.maint (patch-check): Fail if patch generates any output,
3482 even merely for changed offsets.
3484 * src/c99-to-c89.diff: Adjust to reflect new offsets.
3486 * NEWS: Mention changes affecting df, pwd, shred.
3488 2006-05-06 Jim Meyering <jim@meyering.net>
3490 * tests/ls/stat-vs-dirent: New test, to detect the bogus file
3491 system condition where dirent.d_ino != stat.st_ino.
3492 * tests/ls/Makefile.am (TESTS): Add stat-vs-dirent.
3494 2006-05-06 Eric Blake <ebb9@byu.net>
3496 * tests/ls/inode: Expand to test inode from readdir case.
3497 * tests/ls/follow-slink: Expand to test broken links encountered
3498 implicitly, favoring Solaris 9 and OpenBSD 3.4 behavior.
3500 2006-05-06 Eric Blake <ebb9@byu.net>
3502 * tests/mv/leak-fd: Work even on case-insensitive file system.
3504 2006-05-04 Jim Meyering <jim@meyering.net>
3506 * NEWS: Mention the 2006-03-19 pwd-related change that makes
3507 lib/getcwd.c work around inconsistent file system dirent.d_ino data.
3509 2006-05-03 Jim Meyering <jim@meyering.net>
3511 * src/ls.c (DEFINE_SORT_FUNCTIONS, LIST_SORTFUNCTION_VARIANTS):
3512 Use better macro parameter names: s/basename/key_name/,
3513 s/basefunc/key_cmp_func. Fix typo in comment.
3515 2006-04-29 Eric Blake <ebb9@byu.net>
3517 * src/ls.c (main): On systems with d_type, directories_first only
3518 implies format_needs_type, not format_needs_stat.
3520 2006-05-03 Jim Meyering <jim@meyering.net>
3522 * src/ls.c (xstrcoll_df_version, rev_xstrcoll_df_version): Add space
3523 after comma in arg list, from Eric Blake.
3525 2006-04-25 Paul Eggert <eggert@cs.ucla.edu>
3527 * tests/misc/date (relative-3): New test, derived from a bug
3528 report by John Thomas McDole.
3530 2006-04-23 Francesco Montorsi <fr_m@hotmail.com>
3532 New option for ls: --group-directories-first.
3533 It makes ls list directories before files.
3534 * NEWS [New features]: Mention it.
3535 * src/ls.c (sort_type): Rearrange to use as an array index when
3536 choosing sort function; added new sort_numtypes member for
3538 (time_type): Add new time_numtypes member for compile-time check.
3539 (directories_first): New global variable.
3540 (GROUP_DIRECTORIES_FIRST_OPTION): New enum.
3541 (long_options): Add --directories-first.
3542 (main): Support new option.
3543 (is_directory): New function.
3544 (extract_dirs_from_files): Use it.
3545 (DIRFIRST_CHECK, DEFINE_SORT_FUNCTIONS)
3546 (LIST_SORTFUNCTION_VARIANTS): New macros.
3547 (sort_functions): New global variable.
3548 (sort_files): Use it.
3549 (usage): Document new option.
3551 2006-04-18 Paul Eggert <eggert@cs.ucla.edu>
3553 * src/shred.c (fillrand): The assertion was way too weak, due to
3554 what must be a typo. Strengthen it to its intended value.
3555 (dopass): Don't use alloca; it's not worth the aggravation here,
3556 since it's used only to get a page-aligned buffer, and page
3557 alignment doesn't buy us much here. I'm suspicious that alloca
3558 causes problems on some hosts, due to a recent bug report by Adam
3559 Waltman: http://bugs.gentoo.org/130246.
3561 2006-04-18 Jim Meyering <jim@meyering.net>
3563 * tests/misc/tty-eof: Add new programs, base64, sha224sum, sha256sum,
3564 sha384sum, sha512sum.
3566 2006-04-17 Paul Eggert <eggert@cs.ucla.edu>
3568 * src/chmod.c (describe_change): Adjust to filemode changes.
3569 * src/ls.c (HAVE_ST_DM_MODE): Remove; moved to ../lib/filemode.c.
3570 (print_long_format): Use (new) filemodestring rather than
3571 (old) mode_string, so that we get more file types right, at least
3572 in theory. Adjust to filemode changes.
3573 * src/stat.c (human_access): Likewise.
3575 2006-04-18 Jim Meyering <jim@meyering.net>
3577 * src/ptx.c (main) [DEFAULT_IGNORE_FILE]: Remove code to use a default
3578 ignore file. This has never been enabled. Reported by Eric Blake.
3580 2006-04-12 Paul Eggert <eggert@cs.ucla.edu>
3582 * src/ln.c (linkfunc): Remove. This method ran into a compiler/linker
3583 bug in Interix. Just call symlink or link directly. All uses changed.
3584 * src/setuidgid.c (main) [! HAVE_SETGROUPS]: Don't call setgroups.
3585 * src/stat.c (USE_STATVFS): New macro.
3586 Include <sys/statvfs.h> and use statvfs only if USE_STATVFS.
3587 (NAMEMAX_FORMAT): define a bit more clearly, now that the
3588 statvfs-using code is a bit more regular.
3589 * src/system.h (sync) [!HAVE_SYNC]: New macro.
3591 2006-04-11 Paul Eggert <eggert@cs.ucla.edu>
3593 * NEWS: csplit, nl, expr now conform to POSIX better, and are
3594 more-compatible with traditional Unix, with respect to regular
3596 * src/csplit.c (extract_regexp): Set re_syntax_options to a
3597 value that is compatible with what POSIX requires.
3598 * src/nl.c (build_type_arg): Likewise.
3599 * src/expr.c (docolon): Likewise. Also, don't let anchors match
3600 newline; this fixes an incompatibility with tradition and with POSIX.
3601 Don't warn about leading ^. POSIX says it is unspecified whether
3602 ^ is a special character, which means that implementations can
3603 either treat it as special or not, but either way a warning is not
3604 allowed (unless the regexp is otherwise invalid). Instead, anchor
3605 the expression but treat ^ as an anchor; this is the traditional
3606 behavior (e.g., Solaris 10).
3607 (eval4, eval3, eval2): Treat non-numeric args, division by zero,
3608 and the like as invalid expressions (exit status 2), not as
3609 failure of 'expr' (exit status 3). This is more consistent with
3610 how Solaris behaves.
3611 * tests/expr/basic (fail-a): Adjust exit status to match new expr
3612 behavior, for status 2 versus 3.
3614 (bre1, bre2, bre3, bre4, bre5, bre6, bre7, bre8, bre9, bre10):
3615 (bre11, bre12, bre13, bre14, bre15, bre16, bre17, bre18, bre19, bre20):
3616 (bre21, bre22, bre23, bre24, bre25, bre26, bre27, bre28, bre29, bre30):
3617 (bre31, bre32, bre33, bre34, bre35, bre36, bre37, bre38, bre39, bre40):
3618 (bre41, bre42, bre43, bre44, bre45, bre46, bre47, bre48, bre49, bre50):
3619 (bre51, bre52, bre53, bre54, bre55, bre56, bre57, bre58, bre59, bre60):
3620 (bre61, bre62): New tests.
3621 * tests/misc/csplit: Use \{...\} in test RE, to test that we're
3622 conforming to POSIX.
3625 * tests/du/long-from-unreachable: Solaris 8 sh doesn't understand
3626 "if !". Do not assume that 'sed' can handle long, newline-free input.
3627 * tests/du/long-sloop: Likewise. Evaluate expr once, not $n times.
3629 2006-04-10 Paul Eggert <eggert@cs.ucla.edu>
3631 Adjust to new regex.h API (with new fastmap type), and clean
3632 up the regex storage allocation a bit.
3634 * src/csplit.c (struct control): Put re_compiled member at the
3635 end, since it's large. Change regexpr member from char * to bool;
3636 all uses changed. Add new member fastmap.
3637 (extract_regexp): regexp arg is now char const *, not char *.
3638 Don't bother duplicating the regular expression; it's not needed.
3639 Set fastmap from new fastmap member. Don't bother allocating
3640 a buffer, as the regexp code does a better job than we do.
3641 * src/expr.c (docolon): Allocate and use a fastmap.
3642 Don't bother allocating a buffer.
3643 * src/nl.c (body_fastmap, header_fastmap, footer_fastmap):
3645 (build_type_arg): New fastmap arg. All uses changed.
3646 Don't bother allocating a buffer, but set a fastmap.
3647 * src/ptx.c (context_regex_string, word_regex_string): Remove.
3648 (context_regex, word_regex): New vars, replacing the above.
3650 (struct regex_data): New type.
3651 (compile_regex): Renamed from alloc_and_compile_regex, since
3652 we no longer allocate storage. Arg is now a struct regex_data *,
3653 not a const char *. All uses changed. Don't allocate the fastmap;
3654 instead, take it from the caller. Don't convert size_t to int,
3655 to avoid arithmetic overflow problems. Don't bother freeing
3656 storage afterwards; it's not worth the aggravation.
3657 * src/tac.c (compiled_separator_fastmap): New ver.
3658 (main): Use it. Don't bother allocating a buffer.
3660 2006-03-30 Jim Meyering <jim@meyering.net>
3662 * src/dd.c (iwrite): Remove assignment without effect.
3663 Reported by Felix Rauch Valenti.
3665 2006-03-22 Eric Blake <ebb9@byu.net>
3667 * src/ptx.c (usage): Remove mention of --copyright/-C.
3668 (main): Alias --copyright to --version plus a deprecation warning.
3669 * NEWS: Mention this.
3671 2006-03-27 Jim Meyering <jim@meyering.net>
3673 * src/Makefile.am (uptime_LDADD): Add $(POW_LIB), for uptime's
3674 use of strtod. Tiny patch from Nickolai Zeldovich.
3676 2006-03-11 Eric Blake <ebb9@byu.net>
3678 * tests/misc/dirname: New file.
3679 * tests/basename/Makefile.am: Delete.
3680 * tests/basename/basic: Move to...
3681 * tests/misc/basename: ... this new file. Add some tests,
3682 including fixed behavior for //.
3683 * tests/misc/Makefile.am (TESTS): Sort. Add basename, dirname.
3684 * tests/Makefile.am (SUBDIRS): Remove basename.
3685 * configure.ac (AC_CONFIG_FILES): Remove tests/basename.
3687 Improvements to dirname/basename handling on platforms like
3688 cygwin with distinct // and with drive letters.
3689 * NEWS: Document new behavior.
3690 * src/basename.c (main): Don't strip suffix from file system
3692 * src/cp.c (target_directory_operand): Use new last_component.
3693 (ASSIGN_BASENAME_STRDUPA): Likewise. Reduce time spent
3694 traversing the string.
3695 * src/dircolors.c (guess_shell_syntax): Use new last_component.
3696 * src/install.c (target_directory_operand, install_file_in_dir):
3698 * src/ln.c (target_directory_operand, main): Likewise.
3699 * src/ls.c (basename_is_dot_or_dotdot): Likewise.
3700 * src/mv.c (target_directory_operand, movefile): Likewise.
3701 * src/remove.c (rm_1): Likewise.
3702 * src/shred.c (wipename): Likewise.
3703 * src/split.c (next_file_name): Likewise.
3704 * src/su.c (log_su, run_shell): Likewise.
3706 2006-03-23 Paul Eggert <eggert@cs.ucla.edu>
3708 * NEWS: nohup diagnostics are now more precise, and nohup now
3709 redirects stderr to nohup.out if stdout is closed and stderr is a tty.
3710 * src/nohup.c (main): Implement this.
3711 * tests/misc/nohup: Test the new behavior.
3713 2006-03-12 Jim Meyering <jim@meyering.net>
3715 * src/copy.c (set_author): Rename function, from preserve_author.
3717 * src/remove.c (AD_pop_and_chdir): Use new macro,
3718 CYCLE_CHECK_REFLECT_CHDIR_UP, rather than open-coding it.
3720 * src/system.h (SAME_INODE): Remove definition.
3721 Include "same-inode.h", instead.
3723 2006-03-11 Eric Blake <ebb9@byu.net>
3725 * src/pwd.c (robust_getcwd): Prepend only one slash, not two.
3727 2006-03-10 Jim Meyering <jim@meyering.net>
3729 Fix a bug whereby a user with write access to a directory being removed
3730 could cause the removal of that directory to fail with an erroneous
3731 diagnostic about a directory cycle. Reported by Vineet Chadha.
3733 * NEWS: Mention this.
3734 * src/remove.c (AD_pop_and_chdir): If the directory we're about to
3735 leave (and try to rmdir) is the one whose dev_ino is being used to
3736 detect a cycle, reset cycle_check_state.dev_ino to that of the parent.
3738 2006-03-08 Paul Eggert <eggert@cs.ucla.edu>
3740 * NEWS: Document dd's new 'directory' and 'nolinks' flags.
3741 * src/dd.c (set_fd_flags): Handle file-creation flags on file
3742 descriptors, rather than ignoring them.
3743 * tests/dd/misc: Add test cases for append, nofollow, directory,
3744 and nolinks flags. Simplify redirection to /dev/null in some cases.
3746 * tests/dd/misc: iflags->iflag. This fixes a typo that meant the
3747 noatime test never tested anything.
3749 2006-03-05 Paul Eggert <eggert@cs.ucla.edu>
3751 * src/dd.c (flags, usage): New flags directory, nolinks.
3752 * src/system.h (O_NOLINKS): Define to 0 if not already defined.
3754 * src/ls.c (usage): Mention that -f disables --color.
3755 Problem reported by Niels Möller.
3757 2006-03-03 Justin Pryzby <pryzbyj@justinpryzby.com>
3759 * man/*.x: Add references to syscalls from utilities of the same name.
3761 2006-03-05 Jim Meyering <jim@meyering.net>
3763 * tests/help-version: Set SHELL, if not already set, in order to
3764 avoid failure when `make check' is run through debuild; dircolors
3765 would fail due to lack of $SHELL. Reported by Sven Joachim.
3767 Make `base64 --wrap=N' work for N=0, and for N larger than SIZE_MAX.
3768 * src/base64.c (wrap_write, do_encode, main): Change type of
3769 parameters and locals, wrap_column, form size_t to uintmax_t.
3770 (main): Adjust to use xstrtoumax, accordingly.
3772 2006-03-03 Jim Meyering <jim@meyering.net>
3774 Don't fail when run from an environment with SHELL not a Bourne
3775 shell, e.g. `env SHELL=/bin/csh make check' would fail this test.
3776 * tests/dircolors/simple: Invoke each non-failing test with -b.
3777 Reported by Michael Stone.
3779 2006-02-27 Jim Meyering <jim@meyering.net>
3781 * tests/misc/base64: Derive --decode-using tests from the
3784 * tests/misc/base64: Factor out a long constant string.
3785 Split lines to stay within 80 columns.
3787 * tests/misc/Makefile.am (TESTS): Add base64.
3788 * tests/misc/base64: Test base64. From Simon Josefsson.
3790 * src/base64.c (do_decode): Use correct type for parameter,
3791 ignore_garbage: s/size_t/bool/.
3793 * src/base64.c: Don't include .h files already included by system.h:
3794 <string.h>, <stdlib.h>, <stdbool.h>, <limits.h>, <errno.h>.
3795 Include "system.h" before the other lib/*.h header files.
3796 Include <sys/types.h> before "system.h".
3797 (wrap_write): Remove declaration of unused local, initial_column.
3798 (wrap_write): Correct declaration syntax: s/size_t * V/size_t *V/.
3800 * README: Add base64 to the list.
3802 2006-02-17 Simon Josefsson <jas@extundo.com>
3804 New program: base64.
3805 * AUTHORS: Mention base64.
3807 * man/Makefile.am: Build base64.1.
3808 * man/base64.x: New file.
3809 * src/Makefile.am (bin_PROGRAMS): Add base64.
3810 * src/base64.c: New file.
3812 2006-02-25 Eric Blake <ebb9@byu.net>
3814 In ls, avoid calling stat for --inode (-i), when possible.
3815 * src/pwd.c (NOT_AN_INODE_NUMBER, D_INO): Move to ...
3816 * src/system.h: ... here, for use in ...
3817 * src/ls.c (main): ... here. Prefer dirent.d_ino to stat when
3819 (gobble_file): Add inode argument.
3820 (print_dir): Pass inode if available.
3821 (usage): Remove inaccuracy.
3823 2006-02-23 Jim Meyering <jim@meyering.net>
3825 * TODO: Update/correct some obsolete entries.
3827 2006-02-20 Paul Eggert <eggert@cs.ucla.edu>
3829 * doc/coreutils.texi (join invocation): Mention `sort -k 1b,1'.
3830 * src/join.c (usage): Likewise.
3831 Documentation problem reported by Philip Kensche.
3833 2006-02-20 Eric Blake <ebb9@byu.net>
3835 * man/rm.x: Update documentation to match previous patch.
3837 2006-02-18 Eric Blake <ebb9@byu.net>
3839 New option for rm: --interactive=once (-I).
3840 * NEWS: Document it, along with change to rm --interactive.
3841 * TODO: Remove entry for implementing rm -I
3842 * src/rm.c (INTERACTIVE_OPTION): New enum value.
3843 (interactive_type): New enum.
3844 (long_opts): Let interactive take an optional argument.
3845 (interactive_args, interactive_types): New option arguments.
3846 (usage): Document -I, --interactive=WHEN. Use program_name
3847 instead of a basename.
3848 (main): New -I option, new behavior to --interactive.
3849 * tests/rm/interactive-once: New tests.
3850 * tests/rm/interactive-always: Ditto.
3851 * tests/rm/Makefile.am (TESTS): Run them.
3853 2006-02-18 Jim Meyering <jim@meyering.net>
3855 * Makefile.maint (sc_two_space_separator_in_usage): Make the regular
3856 expression match more of the target lines, e.g., those that start with
3857 `-S,' (short option followed by a comma) or that include `=[...]'.
3858 Patch by Nicolas François.
3859 Fix the four offenders thus exposed:
3860 * src/join.c (usage): Use two spaces (not one) to separate the
3861 --first-only option string from its description, so help2man formats
3862 the derived man page properly.
3863 * src/pr.c (usage): Likewise.
3864 * src/uniq.c (usage): Likewise.
3865 * src/install.c (usage): Likewise.
3867 2006-02-15 Jim Meyering <jim@meyering.net>
3869 * Makefile.maint (alpha beta major): For `make major', ensure that the
3870 version string is of the form N.N[.N]*, where N is one or more digits.
3872 2006-02-14 Jim Meyering <jim@meyering.net>
3874 * INSTALL: Update from gnulib.
3876 2006-02-13 Jim Meyering <jim@meyering.net>
3878 * GNUmakefile (all): Emit diagnostics to stderr, not stdout.
3880 2006-02-12 Jim Meyering <jim@meyering.net>
3882 * Makefile.maint (patch-check): New target.
3883 (local-checks-available): Add to the list.
3885 2006-02-11 Jim Meyering <jim@meyering.net>
3887 * src/c99-to-c89.diff: New file.
3888 * src/Makefile.am (EXTRA_DIST): Add c99-to-c89.diff.
3890 * .x-po-check: New file, with exclusions so that `make distcheck'
3892 * Makefile.am (EXTRA_DIST): Add .x-po-check.
3894 rm -r must remove an empty directory, even if it is inaccessible.
3895 * src/remove.c (close_preserve_errno): New function.
3896 (fd_to_subdirp): Don't print a diagnostic in this function.
3897 Do it from the callers instead, unless rmdir succeeds.
3898 (remove_cwd_entries, remove_dir): Adjust callers.
3899 * tests/rm/empty-inacc: New test for the above.
3900 * tests/rm/Makefile.am (TESTS): Add empty-inacc.
3901 * NEWS: Mention this bug fix.
3902 * tests/rm/rm2: Adjust two expected diagnostics, now that they're
3903 a tiny bit less precise: cannot remove `a/1': ... instead of
3904 cannot open directory `a/1': ...
3906 * Makefile.maint (syntax-check-rules): Automatically derive this
3907 list of sc_-prefixed rule names.
3909 2006-02-10 Paul Eggert <eggert@cs.ucla.edu>
3911 * Makefile.maint (CVS_LIST): Don't assume cvsu is available.
3912 (CVS_LIST_EXCEPT): New macro, to simplify exception-processing.
3913 Most uses of CVS_LIST changed to use CVS_LIST_EXCEPT.
3914 (syntax-check-rules): Bring back sc_changelong. (Hmm, why did it
3915 go away? was that an accident?)
3916 (sc_cast_of_argument_to_free, sc_cast_of_x_alloc_return_value):
3917 (sc_cast_of_alloca_return_value, sc_space_tab, sc_prohibit_atoi_atof):
3918 (sc_error_exit_success, sc_file_system, sc_no_if_have_config_h):
3919 (sc_system_h_headers, sc_sun_os_names, sc_trailing_blank):
3920 (sc_two_space_separator_in_usage, sc_unmarked_diagnostics):
3921 (sc_obsolete_symbols, sc_changelog, sc_prohibit_jm_in_m4):
3922 (sc_useless_cpp_parens, makefile-check, m4-check, po-check):
3923 (author_mark_check, makefile_path_separator_check):
3924 Output line numbers, to simplify navigation of Emacs *compilation*
3926 (sc_prohibit_atoi_atof, sc_file_system):
3927 Rework slightly so that Makefile.maint doesn't get reported as a
3928 violation of its own syntax rules.
3929 (sc_dd_max_sym_length): Use ifneq to do nothing, instead of doing
3930 it at run-time (which didn't work with Bison). Fix a makefile typo,
3931 caught by Makefile.maint itself: spaces where a tab should be.
3932 (po-check): Check lib/*.[ch] even if not in CVS; used by Bison,
3933 which copies from ../gnulib/lib/*.[ch] to lib/*.[ch].
3934 Ignore djgpp and man subdirectories, to avoid false matches with
3935 Bison and coreutils, respectively. Use sort -u to remove the
3936 resulting duplicates.
3937 * gnupload: Rework slightly to avoid bogus warning from
3938 sc_two_space_separator_in_usage.
3940 2006-02-10 Jim Meyering <jim@meyering.net>
3942 Use gzip's --rsyncable option only if it's available.
3943 * Makefile.maint (gzip_rsyncable): New variable.
3946 2006-02-08 Jim Meyering <jim@meyering.net>
3948 * Makefile.maint (local-checks-available): Define in terms of
3949 the expansion, $(syntax-check-rules), rather than the single,
3950 top-level target `syntax-check', so that it's easier to exclude
3951 individual rules (via $(local-checks-to-skip)).
3952 (tgz-md5, tgz-sha1, ...): Remove now-unused definitions.
3954 2006-02-07 Jim Meyering <jim@meyering.net>
3956 * src/system.h (!defined O_DIRECT): If O_DIRECTIO is defined (as it
3957 is on Tru64), define O_DIRECT to that. Patch From James Lemley.
3959 * tests/help-version (expected_failure_status_vdir):
3960 Redirect an expected disk-full diagnostic to /dev/null.
3962 2006-02-06 Jim Meyering <jim@meyering.net>
3964 * src/unexpand.c (usage): Use two spaces (not one) to separate the
3965 --first-only option string from its description, so help2man formats
3966 the derived man page properly.
3967 * src/rm.c (usage): Likewise for --no-preserve-root.
3968 * src/chown.c (usage): Likewise.
3969 * src/chgrp.c (usage): Likewise.
3971 Add a rule to ensure that the above doesn't happen again.
3972 * Makefile.maint (sc_two_space_separator_in_usage): New rule.
3973 (syntax-check-rules): Add it.
3974 * .x-sc_two_space_separator_in_usage: New empty file.
3975 * Makefile.am (EXTRA_DIST): Add .x-sc_two_space_separator_in_usage.
3977 2006-02-06 Jim Meyering <jim@meyering.net>
3979 * src/cp.c (usage): Use two spaces (not one) to separate each
3980 option string from its description, so help2man formats the
3981 derived man page properly.
3982 * src/mv.c (usage): Likewise.
3983 Patch from Nicolas François in http://bugs.debian.org/351601.
3985 2006-02-04 Jim Meyering <jim@meyering.net>
3987 * src/copy.c (copy_internal): cp -RL would fail when encountering
3988 the same directory more than once in the hierarchy beneath a single
3989 command-line argument. That is legitimate, e.g. when there are
3990 two or more symbolic links, each pointing to some directory that
3991 would not otherwise be copied. Reported by Christophe LYON.
3992 * tests/cp/cp-deref: New file. Test for today's fix.
3993 * tests/cp/Makefile.am (TESTS): Add cp-deref.
3994 * NEWS: Document this.
3996 2006-02-03 Jim Meyering <jim@meyering.net>
3998 * configure.ac: Require automake-1.9.6, not 1.8.3.
4000 2006-02-01 Paul Eggert <eggert@cs.ucla.edu>
4002 * src/od.c (usage): Mention that -t a ignores high order bit.
4003 Documentation problem reported by Ed Avis.
4005 2006-02-01 Jim Meyering <jim@meyering.net>
4007 * src/pwd.c (find_dir_entry): Remove unused local, `ent_sb_valid'.
4009 2006-01-30 Paul Eggert <eggert@cs.ucla.edu>
4011 * src/head.c (main): Use a better diagnostic when someone uses a
4012 trailing numeric option in an invalid way. Problem reported by
4014 * src/tail.c (parse_options): Likewise.
4016 2006-01-30 Jim Meyering <jim@meyering.net>
4018 * man/wc.x: Include `count' keyword in man page synopsis,
4019 per suggestion from http://bugs.debian.org/181585.
4021 2006-01-24 Paul Eggert <eggert@cs.ucla.edu>
4023 * src/df.c (show_dev): If the file system claims to have
4024 more available than total blocks, report the number of used
4025 blocks as being total - available (a negative number) rather
4026 than as garbage. Problem reported by Toralf Foerster.
4028 2006-01-24 Jim Meyering <jim@meyering.net>
4030 * src/tail.c (tail_forever): Don't exit-nonzero when an attempt
4031 to put a regular file in O_NONBLOCK mode fails with EPERM.
4032 That happens on Linux (up to 2.6.15) when using tail -f on a file with
4033 the append-only attribute. Reported by Dean Gaudet. For details,
4034 see http://savannah.gnu.org/bugs/?func=detailitem&item_id=15473.
4035 * NEWS: Mention this fix.
4036 * tests/tail-2/append-only: New file. Test for the above.
4037 * tests/tail-2/Makefile.am (TESTS): Add append-only.
4038 * tests/Makefile.am (check-root): Add tail-2/append-only
4040 2006-01-21 Jim Meyering <jim@meyering.net>
4042 * NEWS: Mention fts-related improvements and bug fixes.
4044 2006-01-19 Jim Meyering <jim@meyering.net>
4046 * tests/fmt/basic (pfx-1, pfx-2): New tests, to demonstrate the bug
4047 reported as http://bugs.debian.org/147577. Forwarded by Thomas Hood.
4049 2006-01-18 Jim Meyering <jim@meyering.net>
4051 * tests/du/Makefile.am (TESTS): Add long-from-unreadable.
4053 2006-01-17 Jim Meyering <jim@meyering.net>
4055 Now that fts no longer changes the current working directory, adjust
4056 its clients accordingly -- note that du.c uses fts but doesn't need
4057 any adjustment, since it doesn't operate on the actual files,
4058 but rather just uses the stat buffers provided by fts.
4060 * src/chown-core.c: Include "openat.h".
4061 Don't include "lchown.h".
4062 (restricted_chown): Accept a new parameter, CWD_FD, and use it in
4063 calling openat, lchownat, chownat, rather than open, lchown, chown.
4065 * src/chmod.c: Include "openat.h".
4066 (process_file): Use chmodat (fts->fts_cwd_fd,... in place of chmod (...
4068 * tests/du/long-from-unreadable: New test, to exercise one small
4071 2006-01-13 Jim Meyering <jim@meyering.net>
4073 * tests/Makefile.am (SUBDIRS): Add comments discouraging the
4074 addition of new directories under tests/.
4076 * tests/acl: Redirect stdin to /dev/null. Otherwise, FreeBSD 5.0's
4079 2006-01-12 Jim Meyering <jim@meyering.net>
4081 * tests/du/long-sloop: Adjust not to hard-code the expected
4082 diagnostic corresponding to ELOOP. Solaris' diagnostic differs
4083 from that of GNU libc. Reported by Paul Eggert.
4085 * tests/du/long-sloop: Create file at end of symlink chain.
4087 * tests/misc/test: New file, with a test for one of the
4088 bugs fixed by yesterday's test.c changes.
4089 * tests/misc/Makefile.am (TESTS): Add test.
4091 2006-01-11 Jim Meyering <jim@meyering.net>
4093 * tests/du/long-sloop: New file. Test for today's fts.c bug fix.
4094 That bug could make du -L, chgrp -L, or chown -L fail to diagnose
4095 a very long sequence of symbolic links (not necessarily a loop).
4096 * tests/du/Makefile.am (TESTS): Add long-sloop.
4098 2006-01-11 Paul Eggert <eggert@cs.ucla.edu>
4100 * src/test.c (test_syntax_error): Append a newline. All callers
4101 changed, except for the ones that didn't already append a newline.
4102 Bug reported by Eric Blake.
4104 2006-01-11 Jim Meyering <jim@meyering.net>
4106 * src/system.h (X2NREALLOC): Now that verify_true is no longer
4107 void, cast its result to void, to avoid gcc's warning that
4108 ``left-hand operand of comma expression has no effect''.
4109 (DECIMAL_DIGIT_ACCUMULATE, X2REALLOC): Likewise.
4111 2006-01-10 Jim Meyering <jim@meyering.net>
4113 * tests/chmod/no-x: Add a test for today's fts.c fix.
4115 2006-01-10 Jim Meyering <jim@meyering.net> (tiny change)
4117 * src/ls.c (gobble_file): Use DTTOIF only if it's defined.
4118 This is necessary for Dragonfly. Patch by Joerg Sonnenberger.
4120 2006-01-10 Paul Eggert <eggert@cs.ucla.edu>
4122 * src/system.h (X2NREALLOC, X2REALLOC, DECIMAL_DIGIT_ACCUMULATE):
4123 Use verify_true instead of verify_expr, to sync with gnulib.
4125 2006-01-08 Jim Meyering <jim@meyering.net>
4127 * src/date.c (usage): Adjust the formatting of the entries for
4128 %::z and %:::z (separate with two spaces, not one) so that help2man
4129 formats them properly. Reported by Philip Rowlands.
4131 2006-01-06 Paul Eggert <eggert@cs.ucla.edu>
4133 * configure.ac (gl_IGNORE_UNUSED_LIBRARIES): Add.
4135 2006-01-06 Jim Meyering <jim@meyering.net>
4137 * Makefile.maint (copyright-check): Use date +%Y in place of
4140 * src/remove.c (rm_1): Remove `static' attribute on local `status'.
4141 First off, the attribute should have been `volatile' (not static)
4142 to avoid longjmp-related risk of clobber. Secondly, now there is
4143 no longer any risk of a local variable being clobbered, so there's
4144 no need for any attribute at all.
4146 2006-01-05 Jim Meyering <jim@meyering.net>
4148 * src/remove.c: Give a few functions the inline attribute.
4149 (AD_pop_and_chdir): Use gotos to avoid some duplication.
4150 (AD_push): Rewrite an assertion so that the entire computation
4151 goes away when assertions are turned off.
4153 * src/tail.c (ENOSYS) [!defined ENOSYS]: Don't define here.
4154 It's already defined in "system.h".
4155 * Makefile.maint: Add a FIXME comment.
4157 2006-01-04 Jim Meyering <jim@meyering.net>
4159 * ChangeLog: Remove entries from 2005-10-22 and earlier.
4160 * ChangeLog-2005: New file, for entries up to version 5.92.
4162 2006-01-03 Jim Meyering <jim@meyering.net>
4164 * tests/du/no-x: Also allow a slightly different diagnostic -- the
4165 one you get when using openat-enabled fts.c and du (coming soon).
4166 * tests/chmod/no-x: Likewise.
4167 * tests/chgrp/no-x: Likewise.
4169 * src/system.h (O_DIRECTORY) [!defined O_DIRECTORY]: Define.
4171 2006-01-02 Paul Eggert <eggert@cs.ucla.edu>
4173 * src/chown-core.c (RC_do_ordinary_chown): New enum value.
4174 (restricted_chown): Return it, if the file cannot be accessed due
4175 to EPERM, or if no uid or gid are required, or if the file is
4176 neither a directory nor a regular file. Rewrite to avoid gotos.
4177 (change_file_owner): Handle RC_do_ordinary_chown case.
4178 Rewrite to avoid gotos.
4179 * tests/chgrp/basic: Make sure we can change the group of
4182 * src/date.c (usage): Explain %g, %G, and %V a bit better.
4184 2006-01-02 Jim Meyering <jim@meyering.net>
4186 * src/copy.c (set_owner): Correct a comment.
4188 * src/tail.c (parse_options): Change warning to say that --retry
4189 is useful `mainly' (not `only') when following by name.
4190 Reported here: http://bugs.debian.org/273781
4192 2006-01-01 Paul Eggert <eggert@cs.ucla.edu>
4194 * NEWS: Document that mkfifo and mknod -m no longer set special bits.
4195 * src/copy.c: Include lchmod.h.
4196 (copy_internal): Use lchmod rather than chmod.
4197 * src/cp.c: Include lchmod.h.
4198 (re_protect, make_dir_parents_private): Use lchmod rather than chmod.
4199 * src/mkdir.c: Include lchmod.h.
4200 (usage): Clarify -m's operation.
4201 (main): Use lchmod rather than chmod. Don't use lchmod unless the
4202 new mode contains bits outside the 777 range.
4203 * src/mkfifo.c (usage): Clarify -m's operation.
4204 (main): If -m is given, don't invoke chmod; use umask 0 instead.
4205 Report an error if -m asks for bits outside the 777 range.
4206 * src/mknod.c (usage, main): Likewise.
4208 * src/mkdir.c, src/mkfifo.c, src/mknod.c: Undo 2005-12-19 changes.
4210 2005-12-27 Jim Meyering <jim@meyering.net>
4212 * Makefile.maint (sc_obsolete_symbols): Prohibit use of O_NDELAY.
4213 (sc_prohibit_assert_without_use): New rule.
4214 (syntax-check-rules): Add it to the list.
4215 * .x-sc_prohibit_assert_without_use: New empty file.
4216 * Makefile.am (EXTRA_DIST): Add it.
4218 * Makefile.maint (CVS_LIST): Define in terms of $(srcdir).
4220 * cp.c, df.c, link.c, mknod.c, nice.c, sleep.c, unlink.c:
4221 Don't include <assert.h>; it wasn't used.
4223 2005-12-26 Paul Eggert <eggert@cs.ucla.edu>
4225 * src/chown-core.c (restricted_chown):
4226 Don't try O_WRONLY unless O_RDONLY failed wth EACCES.
4227 * src/remove.c (fd_to_subdirp): Open with O_DIRECTORY | O_NOCTTY
4228 | O_NOFOLLOW too, for consistency with other dir-openers.
4229 Use POSIX-preferred O_NONBLOCK rather than O_NDELAY.
4230 (is_empty_dir): Likewise.
4231 * src/shred.c (wipename): Likewise. Don't bother trying to open
4232 dir for writing, since POSIX prohibits it.
4234 2005-12-22 Jim Meyering <jim@meyering.net>
4236 * tests/help-version: Redirect stderr to /dev/full, to suppress
4237 write error diagnostic.
4239 2005-12-19 Jim Meyering <jim@meyering.net>
4241 * src/mkdir.c, src/mknod.c, src/mkfifo.c (main)
4242 Avoid a minor race condition when `-m MODE' is specified, by using
4243 open, fchown, and close rather than just chown. To do that reliably --
4244 even with an overly restrictive umask -- ensure that each mkdir,
4245 mknod and mkfifo call uses a mode including at least owner-read access.
4246 * src/mknod.c (main): When `-m MODE' is specified, exit nonzero if
4247 the subsequent chown (or equivalent open,fchown,close) fails.
4248 * tests/misc/mknod: New tests.
4249 * tests/misc/Makefile.am (TESTS): Add mknod.
4251 2005-12-17 Jim Meyering <jim@meyering.net>
4253 * src/remove.c (is_empty_dir): Open with O_NDELAY, so we don't hang,
4254 e.g., on a named pipe.
4255 (OPEN_NO_FOLLOW_SYMLINK): Remove definition. Use O_NOFOLLOW in
4256 place of all uses, since it is guaranteed (system.h) to be defined.
4258 2005-12-05 Andreas Gruenbacher <agruen@suse.de>
4260 Add POSIX ACL support
4261 * src/ls.c: Switch back from HAVE_ACL to USE_ACL: The acl() syscall
4262 is no requirement for ACL support; particularly, it does not exist
4263 on systems that have POSIX ACLs.
4264 * src/copy.h (cp_option_init) [umask_kill]: Remove member.
4265 * src/cp.c (umask_kill): With default acls, the umask is not to be
4266 applied. Remove umask_kill, don't change the process umask, and let
4267 the kernel apply the umask where appropriate.
4268 * src/cp.c (make_dir_parents_private): Fix logic for POSIX ACLs.
4269 * src/copy.c (get_dest_mode): Remove; it is obsolete after removing
4271 (copy_reg, copy_internal): Use copy_acl and set_acl
4272 instead of fchown/chown. Fix the logic for POSIX ACLs.
4273 (chown_succeded): Remove; we now always copy acls and
4274 preserve S_ISUID, S_ISGID, and S_ISVTX when needed, no matter if we
4275 did a chown before or not.
4276 * src/mv.c, src/install.c (cp_option_init): Don't set umask_kill member.
4277 * src/Makefile.am (dir_LDADD, ls_LDADD, vdir_LDADD, cp_LDADD,
4278 mv_LDADD, ginstall_LDADD): On systems with an ACL library, arrange
4279 to link with it via $(LIB_ACL), for the utilities that need it.
4281 2005-12-16 Paul Eggert <eggert@cs.ucla.edu>
4283 * src/remove.c (OPENAT_CWD_RESTORE__REQUIRE): Remove.
4284 (OPENAT_CWD_RESTORE__ALLOW_FAILURE): Likewise.
4285 (fd_to_subdirp): Remove openat_cwd_restore_allow_failure arg; its
4286 value is now signified by whether cwd_errno is null.
4287 (fd_to_subdirp, remove_dir, rm_1); Change cwd failure indicator from
4288 pointer-to-bool to pointer-to-errno-value. All callers changed.
4289 (rm_1): Don't bother setting a local cwd failure flag and then
4290 ORing it into the caller's. Just set the caller's.
4291 (rm): Use cwd failure errno value to print a slightly-better
4294 2005-12-15 Jim Meyering <jim@meyering.net>
4296 * src/stat.c (print_it): Properly handle a backslash at the
4297 end of a --printf format string. Reported by Paul Eggert.
4298 * tests/misc/stat-printf (end-bs): Add a test for the above.
4300 2005-12-15 Paul Eggert <eggert@cs.ucla.edu>
4302 * tests/acl: Port to pre-POSIX shells like Solaris 8 /bin/sh.
4303 Don't assume /etc/passwd contains user names; use 'id' instead.
4305 2005-12-15 Jim Meyering <jim@meyering.net>
4307 stat: revert behavior of --format=FMT (-c)
4308 stat: add new option: --printf=FMT
4309 * NEWS: Mention this.
4310 * src/stat.c (isodigit, octtobin, hextobin): Define.
4311 (PRINTF_OPTION): Define.
4312 (interpret_backslash_escapes, trailing_delim): New globals.
4313 (usage): Document them. Alphabetize on long option names.
4314 (print_esc_char): New function.
4315 (print_it): Rewrite, in order to handle backslash escapes.
4316 (main): Handle new option. Set globals for --format, too.
4318 * tests/misc/stat-printf: Test --printf and --format.
4319 * tests/misc/Makefile.am (TESTS): Add stat-printf.
4321 2005-12-14 Paul Eggert <eggert@cs.ucla.edu>
4323 * NEWS: sort now reports incompatible options.
4324 * src/sort.c (incompatible_options, check_ordering_compatibility):
4326 (main): Use them. Don't bother with a usage message for
4327 "sort -c a b", for consistency with other error diagnostics.
4328 * tests/sort/Test.pm (incompat1, incompat2, incompat3, incompat4):
4331 * src/cat.c (main): Undo previous change. close_stdout already
4332 does the check, so the previous change wasn't necessary.
4334 2005-12-13 Paul Eggert <eggert@cs.ucla.edu>
4336 * src/cat.c (main): Check for close (STDOUT_FILENO) failure.
4338 2005-12-12 Paul Eggert <eggert@cs.ucla.edu>
4340 Install a more-conservative approach for sort -R. It's the
4341 same basic idea as the existing code, except it uses the full ISAAC
4342 approach (called the "more kosher" approach in the existing comments).
4343 This makes "sort -R" quite a bit slower (about a factor of 2 on my
4344 little tests involving 10000 lines on a 2.4 GHz P4), but I think it's
4345 better to be conservative here at first, and review any performance
4346 improvements carefully.
4347 * .x-sc_require_config_h: Add src/rand-isaac.c.
4348 * src/rand-isaac.h: Remove. All uses now simply include rand-isaac.c.
4349 * src/Makefile.am (noinst_HEADERS): Remove rand-isaac.h.
4350 (shred_SOURCES, sort_SOURCES): Remove.
4351 (EXTRA_DIST): Add rand-isaac.c.
4352 * src/rand-isaac.c: Revert to what used to be in shred.c, without
4353 changing it to allow for varying numbers of words in the state.
4354 Alter so that we include rand-isaac.c directly rather than
4355 compiling it and linking to it. Don't include config.h or
4356 system.h; that's the includer's responsibility.
4357 Omit functions that are specific to shred.
4358 (ISAAC_LOG, ISAAC_WORDS, ISAAC_BYTES, struct isaac_state, ind):
4359 (isaac_step, struct irand_state):
4360 Resurrect these, with the same defns that used to be in shred.c.
4361 (ISAAC_SIZE, isaac_new, isaac_copy): Remove.
4362 (isaac_refill, isaac_seed_start, isaac_seed_data, irand_init, irand32):
4364 (struct isaac_state, isaac_refill, isaac_mix, isaac_init):
4365 (isaac_seed_start, isaac_seed_data, isaac_seed_finish, isaac_seed):
4366 (irand_init, irand32, irand_mod):
4367 Number of words is constant again.
4368 (struct irand_state, irand_init, irand32, irand_mod): Move to shred.c.
4369 * src/shred.c: Include rand-isaac.c rather than rand-isaac.h.
4370 * src/sort.c: Likewise.
4371 * src/shred.c (fillrand, dopass, main): Undo previous change.
4372 (struct irand_state, irand_init, irand32, irand_mod): Moved back here,
4374 * src/sort.c: Don't include md5.h; it wasn't needed.
4375 (struct keyfield): Rename random_hash to random, for consistency
4376 with the other member names. All uses changed.
4377 (usage): Tweak wording to mention STRING for --seed option.
4378 (short_options): Rorder for consistency with other programs.
4379 (rand_state): Now a struct, not a pointer to one. All uses changed.
4380 (HASH_WORDS, HASH_SIZE): Remove.
4381 (get_hash): Remove comments around resbuf size, since we can assume C89.
4382 Use a "more-kosher" (but slower) approach of invoking isaac_refill.
4383 (keycompare): Adjust to the new get_hash.
4385 (badfieldspec): Omit recently-introduced comment; it isn't needed.
4386 (main): Don't set need_random simply because gkey has it set; that
4387 doesn't necessarily mean we'll need random numbers.
4388 Redo seeding to match new get_hash approach.
4390 2005-12-10 Jim Meyering <jim@meyering.net>
4392 * src/Makefile.am (noinst_HEADERS): Add rand-isaac.h.
4394 Avoid shred segfault on 64-bit systems.
4395 * src/rand-isaac.c (isaac_refill): Don't try to negate a
4396 local of type uint32_t. Make the local an `int' instead.
4398 * NEWS: Mention sort's new options.
4400 * src/rand-isaac.c (isaac_mix): Declare to be static.
4401 Mark all other functions as `extern' so the tight-scope
4402 part of `make distcheck' passes once again.
4403 * src/rand-isaac.h (isaac_mix): Remove declaration.
4405 * src/sort.c (get_hash): Change position of `*' in parameter
4406 type to conform with convention.
4407 (main): Split a long line so it fits in 80 columns.
4408 (keycompare): Remove stray SPACE before TAB that was
4409 causing `make distcheck' to fail.
4411 * src/shred.c: Don't include gethrxtime.h. No longer needed.
4413 * tests/misc/sort-rand: New file: basic tests for the new options.
4414 * tests/misc/Makefile.am (TESTS): Add sort-rand.
4416 2005-12-10 Frederik Eaton <frederik@ofb.net>
4418 * src/Makefile.am (sort_LDADD): Add $(LIB_GETHRXTIME).
4419 (shred_SOURCES, sort_SOURCES): New macros, so we compile rand-isaac.c.
4420 * src/rand-isaac.c: New file, containing ISAAC code that was in shred.c.
4421 Make state size runtime-configurable.
4422 (isaac_new, isaac_copy): New functions.
4423 * src/rand-isaac.h: New file.
4424 * src/shred.c: Include rand-isaac.h. Move ISAAC code to rand-isaac.c.
4425 (fillrand, main): Adjust to the fact that the state size is now
4426 runtime-configurable.
4427 * src/sort.c (short_options, long_options, WORDS, keycompare, main):
4428 (usage): Add options --random-sort and --seed to implement a random
4430 Include md5.h and rand-isaac.h.
4431 (get_hash): New function.
4432 (rand_state): New var.
4433 (HASH_WORDS, HASH_SIZE): New macros.
4435 2005-12-09 Paul Eggert <eggert@cs.ucla.edu>
4437 * tests/dd/misc: Add test for dd iflags=noatime.
4439 2005-12-09 Jim Meyering <jim@meyering.net>
4441 * src/sort.c (usage): Mention white space vs -b and -t options.
4444 2005-12-09 Eric Blake <ebb9@byu.net>
4446 * src/test.c (main): Fix misleading comment.
4448 2005-12-07 Paul Eggert <eggert@cs.ucla.edu>
4450 * NEWS: Mention dd's new noatime flag.
4451 * src/system.h (O_NOATIME): Define to 0 if not already defined.
4452 * src/dd.c (flags, usage): Add support for noatime flag.
4454 2005-12-07 Jim Meyering <jim@meyering.net>
4456 Distribute the cvsu script, used only by `make syntax-check'.
4457 * Makefile.am (EXTRA_DIST): Add build-aux/cvsu.
4458 * Makefile.maint (CVS_LIST): Use build-aux/cvsu, now that we
4459 distribute a copy of this script.
4460 * .x-sc_unmarked_diagnostics: Add build-aux/cvsu.
4462 * tests/mv/acl: exit-77 before the trap, not after, if we fail
4463 to create a temporary directory on another partition.
4464 From Andreas Gruenbacher.
4466 2005-12-06 Tomas Pospisek <tpo@sourcepole.ch> (tiny change)
4468 * man/basename.x: Cross-reference to dirname and readlink.
4469 * man/dirname.x: Cross-reference to basename and readlink.
4471 2005-12-05 Andreas Gruenbacher
4473 * src/copy.c [!HAVE_FCHOWN]: Define fchown(...) to -1.
4474 (set_owner, preserve_author): New functions, factored out of copy_reg.
4475 (copy_reg): Use them.
4476 (copy_internal): Use them here, too.
4478 2005-12-04 Jim Meyering <jim@meyering.net>
4480 * src/sleep.c (usage): Say what happens with two or more arguments.
4481 Suggested by Justin Pryzby.
4483 * src/uptime.c (print_uptime): Move decl of `upsecs' into scope
4486 2005-12-03 Jim Meyering <jim@meyering.net>
4488 * src/rm.c (long_opts): Change the name of each undocumented, for-
4489 testing-only option to start with `-', so that it cannot render
4490 ambiguous any prefix it happens to share with some other option name.
4491 Problem reported by Eric Blake.
4492 * src/head.c (long_options): Likewise.
4493 * src/tail.c (long_options): Likewise.
4495 * tests/misc/head-elide-tail: Update uses of undocumented, for-
4496 testing-only --presume* options to start with `---'.
4497 * tests/rm/dangling-symlink: Likewise.
4498 * tests/rm/dir-no-w: Likewise.
4499 * tests/rm/isatty: Likewise.
4501 2005-11-30 Jim Meyering <jim@meyering.net>
4503 * Makefile.maint: Add a comment about cvsu.
4505 2005-11-25 Paul Eggert <eggert@cs.ucla.edu>
4507 * NEWS: df updates for "none", "proc", inaccessible file systems.
4508 * src/df.c (show_point): Ignore inaccessible file systems.
4509 (usage): -a includes dummy file systems, not size-0 file systems.
4511 * src/od.c (unsigned_long_long_int): Renamed from ulonglong_t,
4512 to avoid collision with POSIX name space. All uses changed.
4514 2005-11-24 Jim Meyering <jim@meyering.net>
4516 * tests/Makefile.am (EXTRA_DIST): Add acl to the list.
4517 * tests/acl: Add `$0: ' prefix to diagnostics.
4519 * .x-sc_require_config_h: Add lib/buffer-lcm.c to the list.
4521 2005-11-23 Paul Eggert <eggert@cs.ucla.edu>
4523 * src/copy.c: Improve performance a bit by optimizing away
4524 unnecessary system calls and going to a block size of at least
4525 8192 (on normal hosts, anyway). This improved performance 5% on my
4526 Debian stable host (2.4.27 kernel, x86, copying from root
4527 ext3 file system to itself).
4528 Include "buffer-lcm.h".
4529 (copy_reg): Omit last argument. All callers changed.
4530 Use xmalloc to allocate rather than trusting alloca
4531 (which is unwise with large block sizes).
4532 Declare locals more locally, if possible.
4533 Use uintptr_t words instead of int words, for a bit more speed
4534 when looking for null blocks on 64-bit hosts.
4535 Optimize away reads of zero bytes on regular files.
4536 In the typical case, insist on 8 KiB buffers, at least.
4537 Avoid unnecessary extra call to fstat when checking for sparse files.
4538 Avoid now-unnecessary cast to off_t, and "0L".
4539 Avoid unnecessary test of *new_dst when checking for same owner
4542 2005-11-22 Paul Eggert <eggert@cs.ucla.edu>
4544 * src/remove.c (rm): Don't assume C99 for-loop syntax.
4546 2005-11-22 Jim Meyering <jim@meyering.net>
4548 * src/remove.c (AD_push): Remove debugging cruft.
4550 * tests/rm/unread2 (rm): Change expected diagnostic,
4551 `cannot open directory' to `cannot remove', to align with
4553 * tests/rm/rm2: Ensure that rm now continues removing entries
4554 even after certain types of failure.
4556 * src/remove.c: Rewrite. Now, this module is reentrant on systems
4557 that provide openat (Solaris), and on systems like Linux+procfs
4558 where our openat emulation code is reentrant. This also fixes a
4559 few low-probability leaks and eliminates some code that could,
4560 in very unusual circumstances, cause rm() (via a callee) to exit.
4561 * NEWS: Mention this.
4563 * configure.ac: Put copyright dates all on one line so the
4564 emacs function that updates them works properly.
4566 2005-11-18 Paul Eggert <eggert@cs.ucla.edu>
4568 * configure.ac (AM_PROG_CC_C_O): Add. Needed for CVS Automake.
4569 Problem reported by Eric Blake.
4570 (AC_PROG_CC_STDC): Use this instead of AC_PROG_CC, so that
4571 we get a standard-conforming compiler. This relies on the new
4572 m4/c.m4 file. Note that it's a bit tricky, since c.m4 doesn't
4573 define AC_PROG_CC_STDC; we are relying on Autoconf 2.59 internals.
4574 m4/c.m4 can go away with Autoconf 2.60 comes out.
4576 2005-11-17 Jim Meyering <jim@meyering.net>
4578 * src/remove.c (AD_mark_helper): Make a `char *' parameter `const'.
4579 (AD_mark_current_as_unremovable): Likewise, but for a local.
4582 * tests/mv/acl: Let traps handle removing temporary directories.
4584 Expect acl-related tests to fail, until the corresponding
4585 patches are committed.
4586 * tests/mv/Makefile.am (XFAIL_TESTS): Add acl.
4587 * tests/cp/Makefile.am (XFAIL_TESTS): Likewise.
4589 ACL tests, from Andreas Gruenbacher.
4590 * tests/acl, tests/mv/acl, tests/cp/acl: New files.
4591 * tests/mv/Makefile.am (TESTS): Add acl.
4592 * tests/cp/Makefile.am (TESTS): Add acl.
4594 * src/ls.c (basename_is_dot_or_dotdot): Correct wording in comment.
4596 2005-11-16 Paul Eggert <eggert@cs.ucla.edu>
4598 * NEWS: Improve quality of ln's diagnostics.
4599 * src/ln.c (do_link, usage): Likewise.
4600 (do_link): Don't use alloca on a buffer of unbounded size.
4602 2005-11-16 Jim Meyering <jim@meyering.net>
4604 * tests/cp/fail-perm: Accommodate HPUX. It appears to fail
4605 with EACCES rather than EPERM. Reported by Peter O'Gorman here:
4606 http://article.gmane.org/gmane.comp.gnu.core-utils.bugs/5766
4607 This also affects AIX 4.3.3, according to Ralf Wildenhues, in
4608 http://lists.gnu.org/archive/html/bug-coreutils/2006-05/msg00192.html
4610 2005-11-14 Jim Meyering <jim@meyering.net>
4612 * NEWS (sort): Mention consequences of today's mkstemp-safer.c fix.
4614 2005-11-13 Jim Meyering <jim@meyering.net>
4616 * announce-gen: Accept new option, --gpg-key-id=ID and
4617 emit a blurb telling how to use the .sig files.
4618 * Makefile.cfg (gpg_key_ID): Define.
4619 * Makefile.maint (announcement): Use new option and key.
4621 Require that most .c files include <config.h>.
4622 * Makefile.maint (sc_require_config_h): New rule.
4623 (syntax-check-rules): Add it.
4624 * .x-sc_require_config_h: New file listing exceptions to the
4625 above rule. Some are legit, others are simply grandfathered in.
4626 * Makefile.am (EXTRA_DIST): Add .x-sc_require_config_h here, too.
4628 2005-11-12 Jim Meyering <jim@meyering.net>
4630 * src/checksum.h, src/md5.c, src/sha1sum.c: Remove now-unused files.
4632 2005-11-11 Jim Meyering <jim@meyering.net>
4634 * NEWS: Mention `readlink -f' bug fix in 5.3.0 news.
4635 Mention new readlink options in 5.3.0's `New features' section.
4636 Spotted by Thomas Hood.
4638 2005-11-08 Jim Meyering <jim@meyering.net>
4640 * NEWS: Merge in changes from b5_9x branch.
4642 2005-11-08 Paul Eggert <eggert@cs.ucla.edu>
4644 * NEWS: ls now defaults to --time-style='locale', which in turn acts
4645 like --time-style='posix-long-iso' if the locale settings are messed up.
4646 * src/ls.c (decode_switches): Implement this.
4648 2005-11-08 Jim Meyering <jim@meyering.net>
4650 * tests/du/2g: s/expensive/very expensive/ in a comment.
4653 2005-10-17 Eric Blake <ebb9@byu.net>
4655 * src/ls.c (usage): Fix descriptions of --sort, --time.
4656 Reported by Vitaly A. Ostanin.
4658 2005-11-04 Paul Eggert <eggert@cs.ucla.edu>
4660 * src/ln.c: Include filenamecat.c.
4661 (FILE_BASENAME_CONCAT): Remove.
4662 (do_link): Remove last arg DEST_IS_DIR. All callers changed.
4663 (main): Use file_name_concat, base_name, and strip_trailing_slashes
4664 instead of FILE_BASENAME_CONCAT. This simplifies the code, and avoids
4667 2005-11-04 Jim Meyering <jim@meyering.net>
4669 * src/du.c (process_file): Don't overflow for files of size >= 2^31
4670 on systems with stat.st_blocks of a signed 32-bit type.
4671 This bug causes trouble on some AIX 5.1 systems.
4672 Report and trivial patch from Paul Townsend:
4673 <http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00033.html>
4674 * NEWS: Mention this.
4676 * tests/du/2g: New (very-expensive) test for the above-fixed bug.
4677 * tests/du/Makefile.am (TESTS): Add it here.
4678 * tests/very-expensive: New file.
4679 * tests/Makefile.am (EXTRA_DIST): Add it here.
4680 * tests/cp/perm: Mark this test as `very-expensive', too.
4682 2005-11-02 Paul Eggert <eggert@cs.ucla.edu>
4684 * NEWS: Mention that rm -d and maybe ln -d are scheduled for
4686 * src/remove.h (struct rm_options): Remove unlink_dirs. All uses
4688 * src/rm.c (usage): Don't mention rm -d.
4690 2005-11-02 Jim Meyering <jim@meyering.net>
4692 * tests/dd/skip-seek: Fix typo in comment: s/fileutils/coreutils.
4693 From Andreas Schwab.
4695 * tests/dd/unblock-sync: Redirect stderr to /dev/null so the
4696 `M+N records in/out' lines don't pollute `make check' output.
4698 * tests/dd/skip-seek (sk-seek4): New test, to exercise the bug
4699 fixed on 2005-10-31. This test uses the new, IN_PIPE specifier.
4700 * tests/Coreutils.pm: Accept a new type of input specifier: IN_PIPE,
4701 to indicate that the input file should be piped into the command
4702 under test (via `cat FILE | $prog ...').
4704 * src/remove.c (remove_entry): Emit a better diagnostic when rm
4705 (without -r) fails to remove a directory on a non-Linux system.
4706 This change affects only newer Solaris systems (with priv_*
4707 functions like priv_allocset). Reported by Keith Thompson.
4709 * tests/rm/dir-nonrecur: New file/test for the above fix.
4710 * tests/rm/Makefile.am (TESTS): Add dir-nonrecur.
4712 2005-11-01 Paul Eggert <eggert@cs.ucla.edu>
4714 * NEWS: "tail -c 2 FILE" and "touch 0101000000" now operate as
4715 POSIX 1002.1-2001 requires.
4716 * src/tail.c (parse_obsolete_option): Implement this.
4717 Problem reported by Vincent Lefevre.
4718 * src/touch.c (main): Pass PDS_PRE_2000 to posixtime.
4719 * tests/tail/Test.pm (c-2, c-2-minus, c2, c2-minus): New tests.
4720 (test_vector): Add special cases for _POSIX2_VERSION, and
4721 regularize the old ones a bit.
4722 * tests/touch/obsolescent: Add y2000 test.
4724 2005-10-31 Paul Eggert <eggert@cs.ucla.edu>
4726 * src/dd.c (skip): Fix off-by-one error reported by
4727 Theodoros V. Kalamatianos.
4729 2005-10-30 Paul Eggert <eggert@cs.ucla.edu>
4731 * tests/mkdir/p-3: Require that the test be run as non-root.
4732 Problem and trivial fix reported by Theodoros V. Kalamatianos.
4734 2005-10-28 Paul Eggert <eggert@cs.ucla.edu>
4736 * src/ln.c (FILE_BASENAME_CONCAT): Omit unnecessary slashes in the
4737 boundary between DEST and SOURCE in the result.
4739 2005-10-26 Dmitry V. Levin <ldv@altlinux.org>
4741 * src/md5sum.c (main) [!O_BINARY]: Changed default read mode
4742 back to text, to sync with documentation and for backwards
4745 2005-10-25 Jim Meyering <jim@meyering.net>
4747 * tests/dircolors/simple (other-wr): Add an explicit test for
4748 the dircolors bug (NULL-dereference) fixed yesterday.
4750 2005-10-24 Jim Meyering <jim@meyering.net>
4752 * src/tac.c (tac_file): When determining whether a file is seekable,
4753 also test whether it is a tty. Using only the lseek-based test would
4754 give a false positive on Solaris. Reported by Peter Fales.
4756 2005-10-24 Dmitry V. Levin <ldv@altlinux.org>
4758 * tests/install/d-slashdot: New test, for "install -d" failure.
4759 * tests/install/Makefile.am (TESTS): Add d-slashdot.
4760 * tests/mkdir/p-slashdot: New test, for "mkdir -p" failure.
4761 * tests/mkdir/Makefile.am (TESTS): Add p-slashdot.
4763 2005-10-24 Jim Meyering <jim@meyering.net>
4765 * src/dircolors.c (ls_codes): Add missing comma.
4766 Anonymous report and patch from
4767 http://savannah.gnu.org/bugs/?func=detailitem&item_id=14849
4769 * src/dircolors.c: Add compile-time assertion that the slack_codes
4770 and ls_codes arrays have the same number of elements. This would
4771 have prevented the above-fixed bug.
4773 * src/expand.c (parse_tab_stops): Add a comment to make this function
4774 identical to the one in unexpand.c.
4775 * src/unexpand.c (parse_tab_stops): Adjust syntax to make this function
4776 identical to the one in expand.c.
4778 * src/expand.c (next_file): Don't assume fopen cannot return stdin.
4780 2005-10-23 Jim Meyering <jim@meyering.net>
4782 * src/md5sum.c (digest_check, main): Use ptr_align rather than
4783 a dangerous pointer-value-to-`unsigned' cast.
4784 * NEWS: mention the new sha* programs.
4785 * AUTHORS: Add new sha* programs.
4787 2005-08-28 David Madore <david.madore@ens.fr>
4789 Add new programs: sha224sum, sha256sum, sha384sum, sha512sum.
4790 * README: Add their names to the list.
4791 * src/md5sum.c: Provide framework for computing sha-2 hashes.
4792 * src/Makefile.am (sha224sum, sha256sum, sha384sum, sha512sum):
4793 Rules for compiling sha-2 utilities
4794 (noinst_HEADERS): Remove checksum.h.
4795 * man/sha512sum.x, man/sha384sum.x, man/sha256sum.x, man/sha224sum.x:
4797 * man/Makefile.am (dist_man_MANS): Add the corresponding .1 names.
4798 (sha224sum.1, sha256sum.1, sha384sum.1, sha512sum.1): New dependencies.
4799 * tests/misc/sha224sum, tests/misc/sha256sum: New files.
4800 * tests/misc/sha384sum, tests/misc/sha512sum: New files.
4801 * tests/misc/Makefile.am (TESTS): Add new sha224sum, sha256sum,
4802 sha384sum, sha512sum test scripts here rather that each in its
4805 2005-08-28 David Madore <david.madore@ens.fr>
4807 * tests/sha1sum/basic-1 (million-a): Add the "million a's" test (one
4808 of the FIPS test vectors).
4810 2005-10-23 Jim Meyering <jim@meyering.net>
4812 * configure.ac: Use 6.0-cvs as the version string.
4813 * NEWS: Adjust accordingly.
4818 Copyright (C) 2005, 2006 Free Software Foundation, Inc.
4820 Copying and distribution of this file, with or without
4821 modification, are permitted provided the copyright notice
4822 and this notice are preserved.