summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2011-07-15csplit: don't prematurely terminate cleanup (Bug#9076)Paul Eggert
* src/csplit.c (interrupt_handler): Reset signal to SIG_DFL after deleting the files, so that a second interrupt won't prematurely terminate cleanup. (main): Don't use SA_NODEFER | SA_RESETHAND, as that might allow premature termination of cleanup. Also, this ports better to platforms like NonStop, which don't ahve SA_RESETHAND.
2011-07-15* src/dd.c: Remove obsolete comments re POSIX.Paul Eggert
2011-07-15build: avoid a st_blksize compile failure on some systemsPádraig Brady
* src/stat.c (print_stat): Use ST_BLKSIZE() rather than accessing st_blksize directly, which is not present on NonStop at least. Reported by Joachim Schmitz.
2011-07-15build: avoid a fiemap compile failure on some systemsPádraig Brady
* src/fiemap.h (struct fiemap): Adjust the previous change to the fiemap_extents array, which would also require changes to the sizeof calculations in extent_scan_read(). Instead, only declare the fiemap_extents zero length array on linux, which is the only platform that references this member. This avoids a compilation failure on systems that don't support this non standard construct. We don't use the equivalent C99 flexible array construct so as to have maximum portability. * src/extent-scan.c: Cleanup. Remove a redundant #ifndef.
2011-07-14* src/fiemap.h (struct fiemap.fm_extents): Change size to 1.Paul Eggert
This is for portability to non-GCC C89 and C99 compilers. Original problem, on NonStop, reported by Joachim Schmitz in <http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9077>.
2011-07-14maint: fix warning 'possible use of "=" where "==" was intended'Bernhard Voelker
* src/mktemp.c: maint: avoid warning by using the comma operator rather than an always-true conditional (as suggested by Eric Blake). Reported by Joachim Schmitz in http://debbugs.gnu.org/9064.
2011-07-13doc: describe the file permissions set by mktempBenoît Knecht
* src/mktemp.c (usage): As above, for --help. Reported by Jordi Pujol in http://bugs.debian.org/551093. Wording improvments from Eric Blake.
2011-07-13doc: note the order in which wc counts are printedBenoît Knecht
This information has already been added to the Texinfo manual, but was missing from the --help output. * src/wc.c (usage): As above, for --help. Reported by Vincent Lefevre in http://bugs.debian.org/395430.
2011-07-12build: update gnulib submodule to latestJim Meyering
2011-07-12build: list makeinfo 4.13 as a build-from-git requirementEric Blake
* bootstrap.conf (buildreq): List 4.13 as minimum makeinfo version. Prompted by Joachim Schmitz's report in http://debbugs.gnu.org/9050.
2011-07-11dircolors: highlight .webm multimedia filesBenoît Knecht
* src/dircolors.hin: Add .webm multimedia files. Suggested by Josh Triplett in http://bugs.debian.org/582403.
2011-07-08maint: add syntax-check rule to prohibit "."-terminated "SEE ALSO"Jim Meyering
* cfg.mk (sc_prohibit_man_see_also_period): Prohibit a period at the end of the first line after a "SEE ALSO" marker in man/*.x. With this, we shouldn't have to make any more changes like those in today's commit, f2dabd68.
2011-07-08doc: list all new file system types recognized by stat -fPádraig Brady
NEWS (Improvements): Mention the MQUEUE and PSTOREFS file systems, recognized as of commit 171e1b98.
2011-07-08doc: don't terminate SEE ALSO sections with a periodBenoît Knecht
man-pages(7) explicitly says about SEE ALSO sections: "Do not terminate this with a period." This is also in line with all the other man pages in coreutils. * man/cat.x: Remove period at the end of the SEE ALSO section. * man/tac.x: Likewise.
2011-07-08timeout: handle signals more transparentlyPádraig Brady
* m4/jm-macros.m4: Define HAVE_SETRLIMIT. * src/timeout.c: If the child exited with a signal, raise that signal to the timeout process itself, so that callers may also see the signal status. Use setrlimit to disable core dumps for the timeout process, which would be generated by some signals.
2011-07-08timeout: support cascaded timeoutsPádraig Brady
* src/timeout.c (cleanup): Send signals directly to the child in case it has started its own process group (like a cascaded timeout command would for example). * test/misc/timeout-group: Add a test case. * NEWS: Mention the fix.
2011-07-08timeout: add --foreground to support interactive commandsPádraig Brady
Or more accurately, commands not started from the shell prompt, that are interactive, or need to receive Ctrl-C etc. from the terminal. * doc/coreutils.texi (timeout invocation): Document --foreground. * src/timeout.c (main): Set the foreground flag and don't create a separate group. (cleanup): Only send a signal directly to the monitored command when the foreground flag is set. (usage): Describe --foreground. * tests/misc/timeout-group: Add a new test. * tests/Makefile.am: Reference new test. NEWS: Mention the new option. Reported by Shay Shimony Analysis by Alan Curry Fix suggested by Paul Eggert
2011-07-08doc: note that cp -l creates _hard_ linksBenoît Knecht
This fact was already noted in the Texinfo manual, but not in the output of --help. * src/cp.c (usage): As above, for --help. Reported by Jari Aalto in http://bugs.debian.org/294327.
2011-07-07tests: exercise md5sum's new --strict optionJim Meyering
* tests/misc/md5sum: Exercise new --strict option.
2011-07-07md5sum, sha1sum, etc: accept new option: --strictPatrick Schoenfeld
Use this new option with --check when the input is expected to consist solely of checksum lines. With only --check, an invalid line evokes a warning, but the program can still exit successfully. With --strict, any invalid line makes the program exit non-zero. * src/md5sum.c (strict, STRICT_OPTION): Declare/define. (long_options): Add "strict". (usage): Describe --strict. (digest_check): Count improperly_formatted lines, too, and use that number and the global "strict" to determine the return value. (main): Handle STRICT_OPTION. Reject --strict without --check. * doc/coreutils.texi: Describe it. * NEWS (New features): Mention it.
2011-07-07doc: note date's %k, %l are space-padded and equivalent to %_H and %_IBenoît Knecht
* src/date.c (usage): As above, for --help. * doc/coreutils.texi (Time conversion specifiers): Likewise. Reported by Britton Leo Kerin in http://bugs.debian.org/115833.
2011-07-07stat: recognize GPFS as a file system typeJim Meyering
* src/stat.c (human_fstype) [S_MAGIC_GPFS]: Add a case, to handle GPFS_SUPER_MAGIC/0x47504653. Prompted by this discussion: http://thread.gmane.org/gmane.comp.sysutils.autoconf.general/14007 * NEWS (Improvements): Mention it.
2011-07-02maint: use "const" and "pure" function attributes where possibleJim Meyering
* configure.ac (WARN_CFLAGS): Add -Wsuggest-attribute=const, -Wsuggest-attribute=pure and -Wsuggest-attribute=noreturn. (GNULIB_WARN_CFLAGS): But do not add them here... yet. * src/chown-core.h (chopt_free, uid_to_name): Add function attribute(s). * src/copy.c (is_ancestor, valid_options): Likewise. * src/copy.h (chown_failure_ok): Likewise. * src/dd.c (operand_matches, operand_is): Likewise. * src/df.c (selected_fstype, excluded_fstype): Likewise. * src/expr.c (null looks_like_integer): Likewise. * src/md5sum.c (hex_digits): Likewise. * src/od.c (get_lcm): Likewise. * src/pathchk.c (component_start, component_len): Likewise. * src/pinky.c (count_ampersands): Likewise. * src/pr.c (cols_ready_to_print): Likewise. * src/ptx.c (search_table): Likewise. * src/sort.c (find_unit_order): Likewise. * src/stty.c (mode_type_flag, string_to_baud, baud_to_value): Likewise. * src/system.h (gcd, lcm): Likewise. * src/tr.c (is_char_class_member, look_up_char_class): Likewise. (star_digits_closebracket): Likewise. * src/uniq.c (find_field): Likewise. * src/wc.c (compute_number_width): Likewise. * lib/xfts.h (cycle_warning_required): Likewise. * gl/lib/randint.h (randint_get_source): Likewise. * gl/lib/randperm.c (ceil_lg): Likewise. * gl/lib/randperm.h (randperm_bound): Likewise. * lib/strnumcmp.h (strintcmp): Likewise.
2011-07-02buffer_lcm: declare with _GL_ATTRIBUTE_CONSTJim Meyering
* lib/buffer-lcm.h (buffer_lcm): Use _GL_ATTRIBUTE_CONST. * lib/buffer-lcm.c: Include <config.h>.
2011-07-01doc: detail the effect of disabling input buffering with stdbufPádraig Brady
* docs/coreutils.texi (stdbuf invocation): Expand on the different reasons for disabling buffering on input and output.
2011-07-01doc: mention the restrictions for stdbuf more prominentlyBruno Haible
* doc/coreutils.texi (stdbuf invocation): List the contraints on the command being controlled, up front.
2011-06-25doc: improve ls --help grammarJim Meyering
* src/ls.c (usage): Improve grammar. Reported by Peng Yu.
2011-06-25doc: clarify an improvement from coreutils-7.0Jim Meyering
* NEWS (7.0 Improvements): Mention the command: "ls -1U". * cfg.mk (old_NEWS_hash): Update.
2011-06-25maint: don't use gnulib's pathmax module; define PATH_MAX if neededJim Meyering
* bootstrap.conf (gnulib_modules): Remove pathmax. * src/system.h: Don't include "pathmax.h". (PATH_MAX) [!PATH_MAX]: Define to 8192. Defining it to a constant is preferable to using a definition from pathmax.h that might expand to pathconf ("/", _PC_PATH_MAX). Prompted by discussion leading to: http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/27183/focus=27269
2011-06-25build: bootstrap: remove obsolete gettext-related file exclusionsJim Meyering
* bootstrap.conf: Don't bother to exclude gettext/intl-related .m4 files. That exclusion is no longer necessary.
2011-06-24stat: recognize MQUEUE and PSTOREFS file systemsPádraig Brady
* src/stat.c (human_fstype): Add magic numbers for PSTOREFS and MQUEUE.
2011-06-22tests: stat-free-color: do not count stat calls before mainBernhard Voelker
* tests/ls/stat-free-color: The system may perform additional stat calls upon loading (seen on OpenSuSE-11.4). Count only the number of stat calls compared to --help. This also reduces back to "1" the number of expected calls, effectively reverting part of 2011-06-01 commit, ccf2d9a4.
2011-06-21tests: cp/sparse-fiemap: use "head -n99" in place of "head -99"Bernhard Voelker
* tests/cp/sparse-fiemap: Use "head -n99" in place of "head -99". The latter is officially obsolete.
2011-06-20tests: init.sh: use "sed 1q" in place of "head -1"Jim Meyering
* tests/init.sh (warn_): Use "sed 1q" in place of "head -1". The latter is officially obsolete but more portable than "head -n1". Reported by Bernhard Voelker.
2011-06-20maint: update THANKS.inJim Meyering
* THANKS.in: Remove Stefano's name.
2011-06-20tests: improve init.sh by removing w2_Bernhard Voelker
* tests/init.sh (w2_): Remove, moving contents into... (warn_): ...here. Call self from subshell when IFS must be changed.
2011-06-19tests: avoid extra forks in the testsuiteStefano Lattarini
* tests/shell-or-perl: Prefer the `read' builtin over `grep' to look at the shebang line of test scripts. Since `read' is a special builtin, it might abort the whole program upon failures, so add extra sanity checks, verifying that the test script exists and is readable, before trying to read from it.
2011-06-19tests: make test runner a script, not a shell functionStefano Lattarini
This change implements a more correct and idiomatic use of the features of the Automake-provided 'parallel-tests' harness. Moreover, this change is required in order for the testsuite to continue to work with the new testsuite harness that is planned to be introduced in Automake 1.12 (which, as of the writing date, is still under development and in alpha state). * tests/shell-or-perl: New auxiliary script. * tests/Makefile.am (EXTRA_DIST): Distribute it. * tests/check.mk (TESTS_ENVIRONMENT): Remove definition of the `shell_or_perl_' shell function, whose code has been moved in the new script above (with a few improvements and extensions). Do not use it to run the test scripts. (LOG_COMPILER): New, properly invoking `shell-or-perl'.
2011-06-19stdbuf: fix automake variable name to work with cutting edge automakeJim Meyering
* src/Makefile.am (pkglibexec_PROGRAMS): Rename from pkglib_PROGRAMS. The latter is invalid. Without this change, automake v1.11-373-g9ca6326 and newer (on master) would fail with this: `pkglibdir' is not a legitimate directory for `PROGRAMS' This changes the default installation directory of libstdbuf.so from $prefix/lib/coreutils/ to $prefix/libexec/coreutils/ * src/stdbuf.c (set_LD_PRELOAD): Search in PKGLIBEXECDIR, not PKGLIBDIR, since that's where we install libstdbuf.so. Do not search in "", the system default search path.
2011-06-19maint: avoid a false positive syntax checkPádraig Brady
* cfg.mk (sc_strftime_check): Skip the check when there is no info to compare against. Reported by Stefano Lattarini
2011-06-19maint: typo: insert omitted word in test commentJames Youngman
* tests/misc/sort-spinlock-abuse: Fix typo: s/"very expensive" are/"very expensive" tests are/
2011-06-18maint: fix typo in comment in configure.acStefano Lattarini
* configure.ac ($MAN): Fix typo in explanatory comment.
2011-06-18tests: sort-debug-keys: fix a bug with translated diagnosticsJim Meyering
Ensure that English diagnostics are emitted even when using French sorting rules. * tests/misc/sort-debug-keys: Unset LC_ALL and set LC_COLLATE, LC_CTYPE and LC_NUMERIC to the fr_FR.UTF-8 locale, while setting LC_MESSAGES=C. Reported by Stefano Lattarini.
2011-06-17maint: remove duplicate names from THANKSPádraig Brady
* .mailmap: Merge email addresses * THANKS.in: Remove a duplicate name Reported by Stefano Lattarini
2011-06-17maint: use modules/tempname.diff file, not a replacement; update gnulibJim Meyering
Using a .diff is much more maintainable. Otherwise, changes in the gnulib module description file may not be noticed and merged promptly and may even result in subtle errors. Luckily, this time, the failure to propagate gnulib's changes to modules/tempname resulted only in an obvious link failure. * gl/modules/tempname: Remove file. * gl/modules/tempname.diff: Use a .diff file instead. * gnulib: Update submodule to latest.
2011-06-17tests: avoid sort-spinlock-abuse false positive under heavy loadJim Meyering
* tests/misc/sort-spinlock-abuse: Classify as "very expensive" to avoid unwarranted failure once and for all.
2011-06-17tests: remove skip_test_ function; use new skip_ insteadJim Meyering
* tests/init.cfg (skip_test_): Remove function. Use skip_ in place of skip_test_ everywhere else. * cfg.mk (sc_prohibit_skip_): Remove rule. * tests/**: Use skip_, not skip_test_, everywhere.
2011-06-17tests: make init.sh's warn_ emit to both the tty and the log fileJim Meyering
* tests/init.sh (warn_): When $stderr_fileno_ != 2, emit the diagnostic to both the tty and the log file.
2011-06-17tests: use printf, not echo in init.sh's warn_ functionJim Meyering
* tests/init.sh (warn_): Use printf, not echo. The latter would misbehave when given strings containing a backslash or starting with e.g., -n. James Youngman suggested setting IFS.
2011-06-14tests: accommodate HP-UX and ksh-derived shellsJim Meyering
Running "make check" normally prints a diagnostic to the outermost stderr (usually a tty) to explain why a test is skipped. It did this by redirecting FD 9 to stderr (via "exec 9>&2") before invoking the shell script. Shell scripts write skip-explanation to FD 9 via init.sh's skip_ function. However, with ksh and HP-UX's /bin/sh, the effects of "exec 9>&2" are canceled upon fork-and-exec, so we would get a "Bad file number" diagnostic and no skip explanation on those systems. * tests/check.mk (TESTS_ENVIRONMENT): Redirect more portably, via "$(SHELL) 9>&2", rather than the prior "exec 9>&2; $(SHELL) ..." Actually, we use "shell_or_perl_ 9>&2", to make this effective also for the perl-based tests. * tests/init.sh (stderr_fileno_): Update the advice in comments. See http://thread.gmane.org/gmane.comp.gnu.coreutils.bugs/22488 for lots of discussion. Stefano Lattarini suggested the solution of putting "9>&2" after the command. Reported by Bruno Haible.