summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2008-04-02copy.c: remove an in-function #ifdefJim Meyering
* src/copy.c (rpl_mkfifo) [! HAVE_MKFIFO]: New function. (mkfifo) [! HAVE_MKFIFO]: Define to rpl_mkfifo. (copy_internal): Remove #ifdef. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-04-02HACKING: rename README-contribution-guidelinesJim Meyering
README-contribution-guidelines: Rename to .. HACKING: ...this.
2008-04-01bootstrap: remove dangling *.[ch] symlinks from libJim Meyering
* bootstrap [dangling symlink removal]: Match *.[ch] files, too. Suggestion from Eric Blake.
2008-04-01bootstrap: make find's -depth option be the first.Jim Meyering
* bootstrap [dangling symlink removal]: Move find's -depth option to precede all others, to avoid a warning.
2008-04-01* bootstrap: Remove dangling symlinks from lib (aka $source_base), too.Jim Meyering
2008-04-01Avoid root-only SELinux-related test failures w/o mcstransd.Jim Meyering
When mcstransd is not running (i.e., after service mcstrans stop), "make check" as root would provoke two test failures. * tests/cp/cp-a-selinux: Use the context, root:object_r:tmp_t:s0, that works both with and without mcstransd. Thanks to Eric Paris for the tip and to Ondřej Vašík for alerting me to the problem. Reported by Robert Scheck in <http://bugzilla.redhat.com/436717>.
2008-04-01root tests: Set NON_ROOT_USERNAME if not set already.Jim Meyering
* tests/test-lib.sh (require_root_): This avoids failure of a couple of root-only tests that require a value for that envvar.
2008-04-01texinfo formatting tweaksJim Meyering
* coreutils.texi: Avoid some overfull hbox warnings. (Treating / specially): Use @file{/} rather than a bare /.
2008-04-01printf doc: xref print(3) and libc's "Output Conversion Syntax" nodeJim Meyering
* coreutils.texi (printf invocation): Add xref. Use "The GNU C Library Reference Manual" as the name of the 'libc' document consistently. * man/printf.x: Add See also: printf(3). Suggested by A. Costa in http://bugs.debian.org/465522
2008-03-31Emit "#line 1" right after the two 'read-only/GENERATED' lines.Jim Meyering
* bootstrap (cp_mark_as_generated): This preserves line numbering e.g., in assertions, which is important when correlating between coreutils test failures and the original files in gnulib/tests. Suggested by Eric Blake.
2008-03-31* README-contribution-guidelines: Mention how to amend a commit.Jim Meyering
Suggestion from Pádraig Brady.
2008-03-31Begin documenting contribution guidelines.Jim Meyering
* README-contribution-guidelines: New file. For now, not distributed.
2008-03-31"rm -r DIR" would mistakenly prompt about very long namesJim Meyering
* src/remove.c (write_protected_non_symlink): Return 0(-1) when euidaccess_stat pronounces a writable(not-writable) file, not -1(0). * tests/rm/deep-2: New file. Test for the above-fixed bug. * tests/rm/Makefile.am (TESTS): Add deep-2. Discovered while reviewing this change: http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/13071
2008-03-31* NEWS: Note the dd bug fix. The bug was introduced over 8 years ago:Jim Meyering
9fca49f67c16c8b42c32e185808fe187cedb0fa7
2008-03-31dd bug fix: accept e.g., if=/dev/stdin and of=/dev/stdoutPaul Eggert
* lib/fd-reopen.c: Work even if FILE is "/dev/stdin". Problem reported by Geoffrey Lee in <http://bugs.debian.org/290727>. * tests/dd/misc: Check for this bug.
2008-03-29avoid failure of new test on kernel without SELinux supportJim Meyering
* tests/mkdir/selinux: Also accept ENOENT. Reported by Sven Joachim. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-29tests: accept ENOTSUP message as well as the EINVAL oneJim Meyering
This test would fail on most non-Linux systems because the original expected an "Invalid argument" diagnostic, yet they all produced "Operation not supported". * tests/mkdir/selinux: Accept both strings. Factor out duplication.
2008-03-29Work around a recent glibc/getopt.c diagnostic change.Jim Meyering
* tests/misc/factor: Map new "-- '1'" to expected "-- 1". Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-28mknod, mkfifo: don't segfault when diagnosing invalid SELinux contextJim Meyering
Identical to the bug fixed by 72d052896a9092b811961a8f3e6ca5d151a59be5. * src/mkfifo.c (main): Use "scontext", not NULL optarg in diagnostic. * src/mknod.c (main): Likewise. Reported by Cristian Cadar, Daniel Dunbar and Dawson Engler. * tests/mkdir/selinux: Test for the above fixes. * NEWS: Mention the fixes.
2008-03-28Fix typo in old NEWS and ChangeLog: s/commmand/command/.Jim Meyering
* ChangeLog-2007: Likewise. * NEWS: Likewise. Prompted by http://bugzilla.redhat.com/439410
2008-03-28tests: Factor out code that's going to be reused.Pádraig Brady
* tests/test-lib.sh (mkfifo_or_skip_): New function, factored out of... * tests/touch/fifo: ...here.
2008-03-28Require that "(exit $fail); exit $fail" be last line of each test.Jim Meyering
* maint.mk (sc_require_test_exit_idiom): New rule to enforce policy. * tests/cp/acl: Adhere to the new policy. * tests/cp/preserve-gid: Likewise. * tests/dd/misc: * tests/install/create-leading: * tests/ln/sf-1: * tests/ls/symlink-slash: * tests/misc/help-version: * tests/misc/ls-time: * tests/misc/nice: * tests/misc/shred-remove: * tests/misc/stty: * tests/misc/stty-row-col: * tests/mkdir/p-1: * tests/mkdir/p-2: * tests/mkdir/p-3: * tests/mkdir/p-v: * tests/mkdir/special-1: * tests/mkdir/writable-under-readonly: * tests/mv/acl: * tests/mv/backup-is-src: * tests/mv/diag: * tests/mv/dir-file: * tests/mv/force: * tests/mv/hard-link-1: * tests/mv/i-2: * tests/mv/i-4: * tests/mv/into-self: * tests/mv/into-self-2: * tests/mv/into-self-3: * tests/mv/partition-perm: * tests/mv/to-symlink: * tests/rmdir/ignore: * tests/tail-2/assert: * tests/tail-2/assert-2: * tests/touch/dangling-symlink: * tests/touch/dir-1: * tests/touch/empty-file: * tests/touch/fifo: * tests/touch/no-rights: Likewise. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-28Perform explicit exit-nonzero if the embedded Perl script fails.Jim Meyering
* tests/misc/pwd-long: Add canonical '(exit $fail); exit $fail'. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-27paste -d\\: avoid heap overrun for backslash at end of delim listJim Meyering
* src/paste.c: Include "quotearg.h". (collapse_escapes): Handle backslash-escaped backslash explicitly. Handle unescaped backslash at end of string by returning nonzero, rather than by overrunning memory. (main): Diagnose an invalid delimiter list -- carefully. Reported by Cristian Cadar, Daniel Dunbar and Dawson Engler. * tests/misc/paste-no-nl (delim-bs): Add a test to demonstrate the heap-smashing capability. (delim-bs2): Prior to coreutils-5.1.2, this bug was a little harder to demonstrate: it would corrupt a first-argument containing e.g., \b * NEWS: Mention the bug fix. * tests/misc/Makefile.am (TESTS): Reflect renaming. * tests/misc/paste: Rename from paste-no-nl. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-26* src/join.c (keycmp): Document new parameters.Jim Meyering
2008-03-26Test for mkdir bug fix.Jim Meyering
* tests/mkdir/selinux: New file: test for today's fix. * tests/mkdir/Makefile.am (TESTS): Add selinux.
2008-03-26mkdir -Z x d: don't segfault when diagnosing invalid context "x" (tiny change)Daniel Dunbar
* src/mkdir.c (main): Use "scontext", not NULL optarg in diagnostic. Reported by Cristian Cadar, Daniel Dunbar and Dawson Engler. * NEWS: Mention the bug fix.
2008-03-25id bug fix: don't point to potentially clobbered static storagePeter Fales
On at least Mac OS, when calling getpwuid twice with the same UID, the static storage containing results from the first call is invalidated by the second call. * src/id.c (main): Point to a copy of the user name string.
2008-03-25Use new gnulib gnumakefile module.Eric Blake
* bootstrap.conf (gnulib_modules): Pull in new module. * GNUmakefile: Remove from version control. * .gitignore: Update. * configure.ac (AC_CONFIG_LINKS): Delete; rely on gnulib to do this now. * Makefile.am (EXTRA_DIST, distclean-local): Likewise. Signed-off-by: Eric Blake <ebb9@byu.net>
2008-03-25join bug fix: adapt keycmp to work with new order-checking featureJim Meyering
* src/join.c (keycmp): Add two join-field parameters. (check_order, join): Update callers. Reported by Dmitry V. Levin in http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/12731/focus=13017 * tests/join/Test.pm (chkodr-7): New test for this fix.
2008-03-23join.c: syntax/style tweaksJim Meyering
* src/join.c (check_order): Rename from checkorder. Move definition to precede first use and remove prototype. Use EXIT_FAILURE, rather than "1". (key_cmp): Move definition to precede first use.
2008-03-22portability: work around a "busybox sed" limitationJim Meyering
* configure.ac: While every other sed tested supports usage like '/\(re\)/{s//\1/;...<NEWLINE>}', and POSIX appears to requires this, busybox's sed does not support it. So duplicate the regexp: '/\(re\)/{s/\(re\)/\1/;...<NEWLINE>}'. Reported by Vincent Lefevre: <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/13013>.
2008-03-21* src/c99-to-c89.diff: Adjust seq.c offsets.Jim Meyering
2008-03-21ptx: avoid heap overrun for backslash at end of optarg stringJim Meyering
* src/ptx.c (copy_unescaped_string): Ignore a lone backslash at end of string. Reported by Cristian Cadar, Daniel Dunbar and Dawson Engler. Details here: <http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/13005>. * tests/misc/Makefile.am (TESTS): Add ptx-overrun. * tests/misc/ptx-overrun: New file. Test for the above fix. * NEWS: Mention the fix. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-21ptx.c readabilityJim Meyering
* src/ptx.c (copy_unescaped_string): Add braces around 80+-line single-stmt while-loop body. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-21Write NEWS and update c99-to-c89 patch for today's rm improvement.Jim Meyering
* NEWS: call this a "portability improvement" ;-) * src/c99-to-c89.diff: Adjust remove.c offsets.
2008-03-21remove.c: Accommodate systems with negative errno values.Ingo Weinhold
* src/remove.c (cache_fstatat): Store errno value directly in the st_ino field, rather than trying to shoehorn it into st_size. This is required at least on BeOS and Haiku.
2008-03-21* src/seq.c (long_double_format): Add a comment.Jim Meyering
2008-03-21* GNUmakefile: Update from gnulib.Jim Meyering
2008-03-20Remove today's automake kludge, altogether. Fix properly.Jim Meyering
* man/Makefile.am: Use dist_man1_MANS instead of dist_man_MANS. Suggestion from Ralf Wildenhues.
2008-03-20Add a check to detect this problem, in case it reappears.Jim Meyering
* maint.mk (my-distcheck): Run "make install", and then ensure that ls.1 is installed.
2008-03-20Kludge to make automake generate install-man rulesJim Meyering
* man/Makefile.am (dist_man_MANS): Add a literal, rm.1. Without this, "make install" would not install man pages. However, with this kludge, the rm.1 man page is installed even when you configure with --enable-no-install-program=rm.
2008-03-20Revert recent man/Makefile.am change.Jim Meyering
Revert 4b544e447eb78fd1f031a026a499f6aed177808a. * man/Makefile.am: That change was only a band-aid. It solved the stated problem, but not a deeper one: that "make install" would no longer man pages. Reported by Dmitry V. Levin. The latter problem arose in 167b8025aca487de001da2448c1aebc2747bc1d3 with the removal of the sole literal from the definition of dist_man_MANS. When automake perceives dist_man_MANS as empty, it no longer emits the install-man* rules.
2008-03-20Sync GNUmakefile with gnulib.Eric Blake
* GNUmakefile (Makefile.cfg): Rename... (cfg.mk): ...to this, and make optional. (GNUmakefile.cfg): Delete, redundant with cfg.mk. (Makefile.maint): Rename... (maint.mk): ...to this. (all) [!_have-Makefile]: Rename... (abort-due-to-no-makefile): ...to this, and invoke via .DEFAULT_GOAL to pick up all targets. * Makefile.cfg: Rename... * cfg.mk: ...to this. * Makefile.maint: Rename... * maint.mk ...to this. (ME): Reflect rename. (makefile-check, m4-check, author_mark_check, msg): Use $(ME) rather than hard-coded name. * Makefile.am (EXTRA_DIST): Distribute renamed files. * .x-sc_file_system: Remove Makefile.maint along with others. No longer needed. * .x-sc_obsolete_symbols: Likewise. * .x-sc_prohibit_atoi_atof: Reflect renaming and remove no-longer-VC'd names. * TODO: Likewise. Signed-off-by: Eric Blake <ebb9@byu.net>
2008-03-19make check: Remove /tmp/ls-creating debug code.Bob Proulx
* tests/misc/ls-misc: Remove debug code creating /tmp/ls.
2008-03-19bootstrap: restore kludge removed on 2008-03-12: it's still necessary.Jim Meyering
* bootstrap: Make the gnulib-tests/test-*.sh scripts executable. This restores code removed by dec8bb25bb6da2fe9fe6dd63c0fbbd593a0e94cb. Reported by Bob Proulx. Signed-off-by: Jim Meyering <meyering@redhat.com>
2008-03-19Check for -- and remove -- some unnecessarily included header files.Jim Meyering
* Makefile.maint: Add checks for a handful of additional header files. * src/mktemp.c: Don't include "long-options.h". Not used. * src/pr.c: Don't include "inttostr.h". Not used. * src/printenv.c: Don't include "error.h". Not used. * src/test.c: Don't include "error.h". Not used. * src/touch.c: Don't include "safe-read.h". Not used.
2008-03-19Remove more vestiges of CVS.Jim Meyering
* Makefile.maint (VC_LIST): Rename from CVS_LIST. (VC_LIST_EXCEPT): Rename from CVS_LIST_EXCEPT.
2008-03-19mv: never unlink a destination file before calling renameJim Meyering
While cp --preserve=links must unlink certain destination files, mv must never do that. * src/copy.c (copy_internal): Pull the '! x->move_mode' test "up", so it affects the entire condition, and not just DEREF_NEVER mode. Reported by James Ralston in <http://bugzilla.redhat.com/438076>. * tests/mv/atomic2: New file. Test for the above fix. * tests/mv/Makefile.am (TESTS): Add atomic2. * NEWS: Mention the bug-fix. [Bug introduced in 367719ba5f1dbd5e2f7fa2466c441f23f66a7c9e]
2008-03-19"make" would not always update man/*.1 files (but "make dist" would)Jim Meyering
* man/Makefile.am (BUILT_SOURCES): Define, so that "make" always updates man/*.1 files. Reported by Bob Proulx.