Re: RFC: avoid chroot() call if not changing root dir

2014-05-16 Thread Pádraig Brady
On 05/16/2014 03:43 PM, Eric Blake wrote: On 05/16/2014 08:08 AM, Pádraig Brady wrote: From 17a185c8e02a56fa09f91ce97151d4e071ecf236 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A1draig=20Brady?= p...@draigbrady.com Date: Tue, 13 May 2014 15:56:34 +0100 Subject: [PATCH] chroot: don't chdir

Re: RFC: avoid chroot() call if not changing root dir

2014-05-17 Thread Pádraig Brady
On 05/17/2014 01:03 AM, Bernhard Voelker wrote: On 05/16/2014 11:02 PM, Pádraig Brady wrote: Pushed. Sorry, a bit late ... + /* Only do chroot specific actions if actually changing root. + The main difference here is that we don't change working dir. */ + if (! STREQ (argv[optind

Re: RFC: dropping privs in chroot --user

2014-05-17 Thread Pádraig Brady
On 05/17/2014 01:45 AM, Bernhard Voelker wrote: On 05/16/2014 10:59 PM, Pádraig Brady wrote: Thanks for the detailed tests. [[ chroot --user=+5000 / id -G ]] before: 0 1 2 3 4 6 10 after: src/chroot: failed to get primary group While the logic behind may be okay, our users

Re: RFC: dropping privs in chroot --user

2014-05-18 Thread Pádraig Brady
On 05/17/2014 12:48 PM, Pádraig Brady wrote: On 05/17/2014 01:45 AM, Bernhard Voelker wrote: On 05/16/2014 10:59 PM, Pádraig Brady wrote: Thanks for the detailed tests. [[ chroot --user=+5000 / id -G ]] before: 0 1 2 3 4 6 10 after: src/chroot: failed to get primary group While

Re: RFC: avoid chroot() call if not changing root dir

2014-05-18 Thread Pádraig Brady
On 05/17/2014 10:40 AM, Pádraig Brady wrote: On 05/17/2014 01:03 AM, Bernhard Voelker wrote: On 05/16/2014 11:02 PM, Pádraig Brady wrote: Pushed. Sorry, a bit late ... + /* Only do chroot specific actions if actually changing root. + The main difference here is that we don't change

[PATCH] tests: use chroot --user rather than internal setuidgid tool

2014-05-19 Thread Pádraig Brady
* init.cfg (require_root_): Adjust to use chroot, and make `require_built_ chroot` implicit when chroot used in the test. * po/POTFILES.in: Remove reference to setuidgid tool. * src/.gitignore: Likewise. * src/local.mk: Likewise. * src/setuidgid.c: Remove. * tests/cp/preserve-gid.sh:

[PATCH] stdbuf: support compilers other than __GNUC__

2014-05-21 Thread Pádraig Brady
__SUNPRO_C = 0x590 /*12.0*/ supports __attribute((constructor)) required by stdbuf, so use a more direct check for this. Note ensure that --libexecdir is set to the appropriate install location for libstdbuf.so so that stdbuf works when installed on the system like it does when running tests in

[PATCH] maint: use consistent widths for comparison of file system constants

2014-05-21 Thread Pádraig Brady
* src/stat.c (human_fstype): Adjust a couple of existing constants to be a consistent width so that the src/fs-magic-compare target works without reporting false positives. * cfg.mk (sc_fs-magic-compare): A new syntax check to enforce this. --- cfg.mk |9 + src/stat.c |4 ++--

Re: [PATCH] maint: use consistent widths for comparison of file system constants

2014-05-22 Thread Pádraig Brady
On 05/22/2014 03:28 AM, Jim Meyering wrote: q Nice. Thanks! What do you think about using e.g., grep -vE '^0x(|)$' instead of that latter sed invocation? Then any offending hex string would be printed. Well the previous did actually print the offending hex strings (since

Re: stat: added features: `--files0-from=FILE', `--digest-type=WORD' and `--quoting-style=WORD'

2014-05-22 Thread Pádraig Brady
On 05/22/2014 09:44 AM, Stefan Vargyas wrote: Dear maintainers, Since coreutils v8.9 I was using a customized 'stat', which has the additional features implied by the command line options and by the format sequence shown below: Thanks for the patch. It's cleanly implemented in a table

Re: stat: added features: `--files0-from=FILE', `--digest-type=WORD' and `--quoting-style=WORD'

2014-05-22 Thread Pádraig Brady
On 05/22/2014 03:05 PM, Stefan Vargyas wrote: Date: Thu, 22 May 2014 12:28:22 +0100 From: Pádraig_Brady p...@draigbrady.com Subject: Re: stat: added features: `--files0-from=FILE', `--digest-type=WORD' join -j2 (stat -c '%s %n' /bin/ls /bin/cp | sort) (sha1sum /bin/cp /bin/ls | sort)

[PATCH] stat,tail: improve support for LogFS and ConfigFS

2014-05-22 Thread Pádraig Brady
* src/stat.c (human_fstype): Add new file system ID definitions. * NEWS: Mention the improvement. --- NEWS |6 +++--- src/stat.c |4 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/NEWS b/NEWS index ced356c..9679b46 100644 --- a/NEWS +++ b/NEWS @@ -110,9 +110,9

[PATCH] doc: clarify --zero-terminated option

2014-05-22 Thread Pádraig Brady
* src/join.c (usage): Reword to avoid implication that the NUL byte is only generated as the output delimeter. * src/sort.c (usage): Likewise. * src/shuf.c (usage): Likewise. Also since we're changing the translation string take the opportunity to separate out the description to a separate string

Re: [PATCH] doc: clarify --zero-terminated option

2014-05-23 Thread Pádraig Brady
I noticed a few more inconsistencies in the description of the various --zero options, so I amended to the attached. cheers, Pádraig. From 54d17616c3e7e45a634adbfa3cf73087b435d51d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A1draig=20Brady?= p...@draigbrady.com Date: Fri, 23 May 2014 00:45:57

Re: RFC: doubling IO_BUFSIZE

2014-05-24 Thread Pádraig Brady
On 05/24/2014 06:32 AM, Jim Meyering wrote: It looks like it makes sense to double IO_BUFSIZE once again. What do you think? +1 Significant enough to bump up I think, and we never saw regressions with this size. Please amend the date etc. at the top of the comment too. Here are the results

Re: RFC: doubling IO_BUFSIZE

2014-05-25 Thread Pádraig Brady
On 05/24/2014 05:21 PM, Jim Meyering wrote: On Sat, May 24, 2014 at 1:59 AM, Pádraig Brady p...@draigbrady.com wrote: On 05/24/2014 06:32 AM, Jim Meyering wrote: It looks like it makes sense to double IO_BUFSIZE once again. What do you think? +1 Significant enough to bump up I think

Re: [PATCH] doc: use nicer quotes

2014-05-25 Thread Pádraig Brady
On 05/24/2014 04:43 PM, Paul Eggert wrote: * doc/coreutils.texi: Add @documentencoding UTF-8. --- doc/coreutils.texi | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/coreutils.texi b/doc/coreutils.texi index 592f4a6..a6dd075 100644 --- a/doc/coreutils.texi +++ b/doc/coreutils.texi

Re: [PATCH] doc: use nicer quotes

2014-05-25 Thread Pádraig Brady
On 05/25/2014 09:26 PM, Paul Eggert wrote: Pádraig Brady wrote: I didn't notice any quoting changes in the generated info or pdf file at least. I think it depends on the Texinfo version. I'm using texinfo 5.2, the latest stable version. Ah right I was using 4.13a on this system. My

Re: [PATCH] build: uname: avoid shadowing warning

2014-05-26 Thread Pádraig Brady
On 05/25/2014 11:21 PM, Jim Meyering wrote: Surprised to find any shadowing warnings in coreutils. This was guarded by __APPLE__ +1 thanks, Pádraig.

Re: Why the memory usage of sort does not seem to increase as the input file size increases?

2014-05-26 Thread Pádraig Brady
On 05/26/2014 04:38 PM, Peng Yu wrote: Hi, I tried sort on some large file. But the memory usage of sort does not seem to be large. This seems to be strange to me, as I think that sort need to see all the data before completing the sorting process. Shouldn't the memory usage of sort

Re: [PATCH] tests: skip chroot test if program not built

2014-06-02 Thread Pádraig Brady
On 06/02/2014 07:25 AM, Bernhard Voelker wrote: I noticed the following, missing require_built_ chroot in another test when looking through latest chroot changes. As an alternative, we could directly add the check to the 'print_ver_' function. WDYT? Have a nice day, Berny From

Re: true,false: --version,--help exit code

2014-06-03 Thread Pádraig Brady
On 06/03/2014 08:50 AM, Bernhard Voelker wrote: Q: Why does 'true --help /dev/full' return 1? Longer story: I was wondering why 'false --version' exits with 1, so looking up the POSIX specification [0] made it clear: The false utility shall always exit with a value other than zero.

Re: true,false: --version,--help exit code

2014-06-03 Thread Pádraig Brady
On 06/03/2014 01:12 PM, Eric Blake wrote: On 06/03/2014 05:28 AM, Bernhard Voelker wrote: yes, sure, but ... wait, a test was failing; the following fixes it: diff --git a/gnulib b/gnulib index a10acfb..2f40bc5 16 --- a/gnulib +++ b/gnulib @@ -1 +1 @@ -Subproject commit

Re: true,false: --version,--help exit code

2014-06-03 Thread Pádraig Brady
On 06/03/2014 03:41 PM, Jim Meyering wrote: On Tue, Jun 3, 2014 at 7:23 AM, Jim Meyering j...@meyering.net wrote: On Tue, Jun 3, 2014 at 5:16 AM, Pádraig Brady p...@draigbrady.com wrote: On 06/03/2014 01:12 PM, Eric Blake wrote: ... Oh, good point. Maybe it's better to consistently have

Re: tac feature suggestion

2014-06-03 Thread Pádraig Brady
On 06/03/2014 06:13 PM, braultbaron wrote: Hello, I have a feature suggestion for tac. This would be an option: -c --bytes=N where N would mean ignore the last N bytes of the file. In other words, tac --bytes=N file would produce the same output as: head --bytes=-N file | tac

Re: RFC: dd oflag=trunc to support in place filtering of files

2014-06-06 Thread Pádraig Brady
On 06/06/2014 07:34 AM, Bernhard Voelker wrote: On 06/05/2014 03:27 PM, Pádraig Brady wrote: The thought just occurred to me that this could be useful to filter large files in place? For example: grep whatever file.big | dd bs=1M conv=notrunc oflag=trunc I guess you meant

Re: RFC: [PATCH] build: Option for building all tools in a single binary

2014-06-09 Thread Pádraig Brady
On 06/09/2014 02:14 PM, Eric Blake wrote: On 06/08/2014 04:33 AM, Pádraig Brady wrote: On 06/07/2014 09:37 PM, Alex Deymo wrote: Add the --enable-single-binary option to the configure file. When enabled, this option builds a single binary file with all the selected tools in it. Which tools

Re: RFC: [PATCH] build: Option for building all tools in a single binary

2014-06-09 Thread Pádraig Brady
On 06/09/2014 05:18 PM, Alex Deymo wrote: On Sun, Jun 8, 2014 at 3:33 AM, Pádraig Brady p...@draigbrady.com wrote: This seems like a very useful option, thanks! Yes given that there are around 100 utils, amalgamation like this reduces overhead significantly. For a change this size we'd need

Re: RFC: [PATCH] build: Option for building all tools in a single binary

2014-06-09 Thread Pádraig Brady
On 06/09/2014 05:56 PM, Pádraig Brady wrote: On 06/09/2014 05:18 PM, Alex Deymo wrote: On Sun, Jun 8, 2014 at 3:33 AM, Pádraig Brady p...@draigbrady.com wrote: This seems like a very useful option, thanks! Yes given that there are around 100 utils, amalgamation like this reduces overhead

[PATCH] build: update gnulib submodule and tests/init.sh to latest

2014-06-11 Thread Pádraig Brady
* gnulib: Update to latest. * tests/init.sh: Update from gnulib. --- gnulib|2 +- tests/init.sh |2 ++ 2 files changed, 3 insertions(+), 1 deletions(-) diff --git a/gnulib b/gnulib index a10acfb..c6e14bb 16 --- a/gnulib +++ b/gnulib @@ -1 +1 @@ -Subproject commit

Re: [PATCH] build: update gnulib submodule and tests/init.sh to latest

2014-06-11 Thread Pádraig Brady
On 06/11/2014 02:44 PM, Bernhard Voelker wrote: On 06/11/2014 01:19 PM, Pádraig Brady wrote: * gnulib: Update to latest. * tests/init.sh: Update from gnulib. What about bootstrap? nothing new in gnulib's version

[PATCH] tests: fix version printing for ginstall in one test

2014-06-11 Thread Pádraig Brady
* tests/install/d-slashdot.sh: 'ginstall' is the binary name in the build directory, not 'install'. --- tests/install/d-slashdot.sh |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/tests/install/d-slashdot.sh b/tests/install/d-slashdot.sh index 415eb4f..044b8bf 100755 ---

[PATCH] maint: suppress a theoretical buffer overflow warning

2014-06-11 Thread Pádraig Brady
* src/numfmt.c (double_to_human): The printf format is built up in a stack buffer which is big enough to hold any of the possible formats. However the size parameter passed to snprintf was too big by 1 when GROUP was true. So decrease the buffer available to snprintf to avoid this theoretical in

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-06-12 Thread Pádraig Brady
On 06/12/2014 04:51 AM, Alex Deymo wrote: Awesome review! Thanks. Some comments below. On Tue, Jun 10, 2014 at 7:36 AM, Pádraig Brady p...@draigbrady.com wrote: We usally send patches around in git am format to ease processing. I.E. format-patch --stdout -1 to-attach.patch Ok, I'll

Re: When Streaming - 'dd' Value too large for defined data type

2014-06-12 Thread Pádraig Brady
On 06/12/2014 09:31 AM, rogerx@gmail.com wrote: I have a script which uses 'dd' (instead of 'cat') for capturing a timed DVB stream or feed for 30, 60, 90, ... minutes. (From memory, I stopped using 'cat' a long time ago either because 'cat' had problems with TV channels containing

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-06-16 Thread Pádraig Brady
On 06/16/2014 08:02 AM, Alex Deymo wrote: Hi again, 1. If I set main with noreturn: int main (int argc, char **argv) ATTRIBUTE_NORETURN; ...then I get this error, presumably because of the implicit return 0 on main... So I opted for adding ATTRIBUTE_NORETURN only when the main function

Re: [PATCH] df: use the last device name provided by the system

2014-06-17 Thread Pádraig Brady
On 05/29/2014 03:45 PM, Pádraig Brady wrote: The device name reported for a particular mount entry may no longer be valid if the mount point was subsequently mounted on a different device. Therefore honor the order of the mount list returned by the system and use the last reported device

Re: `du` check for directory loop avoidance

2014-06-19 Thread Pádraig Brady
On 12/18/2013 05:39 PM, Eric Blake wrote: On 12/18/2013 09:46 AM, Jeff Kirkpatrick wrote: However, I don't see explicit reasons for the non-zero exit code. If you want to ask for the reason, you may write an emailto coreutils@gnu.org. Can anyone elaborate on why the decision to use a non-zero

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-06-20 Thread Pádraig Brady
On 06/20/2014 10:36 AM, Alex Deymo wrote: On Thu, Jun 19, 2014 at 4:24 PM, Bernhard Voelker m...@bernhard-voelker.de wrote: # '/bin/sh -i', rather than '/bin/sh -- -i', which doesn't do what we want. # Avoid the issue by using an executable rather than a script. # Test -u, rather than -i,

Re: [PATCH] 'id' prints incorrectly groups for the session

2014-06-25 Thread Pádraig Brady
On 06/25/2014 01:17 PM, Petr Stodůlka wrote: Hi, command 'id' prints wrong groups for the session. This is similar to reported bug #7320 [0], which was patched earlier for 'groups' and 'id -G', however just 'id' still prints wrong groups. I propose this patch based on previous solution:

Re: [PATCH] 'id' prints incorrectly groups for the session

2014-06-26 Thread Pádraig Brady
On 06/26/2014 06:44 AM, Bernhard Voelker wrote: On 06/26/2014 03:53 AM, Pádraig Brady wrote: diff --git a/tests/id/setgid.sh b/tests/id/setgid.sh index aa43ea3..a81b42c 100755 --- a/tests/id/setgid.sh +++ b/tests/id/setgid.sh @@ -1,5 +1,5 @@ #!/bin/sh -# Verify that id -G prints the right

[PATCH] maint: mention when the du cycle warning bug was introduced

2014-06-26 Thread Pádraig Brady
* NEWS: Mention bug introduced in v8.1 (with commit v8.0-88-g8ba5d1a). --- NEWS |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/NEWS b/NEWS index e5ea77c..4e90b79 100644 --- a/NEWS +++ b/NEWS @@ -53,6 +53,7 @@ GNU coreutils NEWS-*-

[PATCH] maint: use predetermined NON_ROOT_GROUP in tests

2014-06-26 Thread Pádraig Brady
* tests/misc/chroot-credentials.sh: Avoid gid lookup. * tests/misc/truncate-owned-by-other.sh: Likewise. * tests/touch/now-owned-by-other.sh: Likewise. * tests/id/setgid.sh: Use previously looked up gid as a more accurate base for the subseuqent adjustment, and move the uid lookup within chroot,

Re: [PATCH] maint: use predetermined NON_ROOT_GROUP in tests

2014-06-26 Thread Pádraig Brady
On 06/26/2014 01:25 PM, Bernhard Voelker wrote: On 06/26/2014 01:47 PM, Pádraig Brady wrote: * tests/misc/chroot-credentials.sh: Avoid gid lookup. Good catch! * tests/misc/truncate-owned-by-other.sh: Likewise. * tests/touch/now-owned-by-other.sh: Likewise. * tests/id/setgid.sh: Use

Re: bug#7320: [PATCH] 'id' prints incorrectly groups for the session

2014-06-26 Thread Pádraig Brady
On 06/26/2014 05:42 PM, Jim Meyering wrote: On Thu, Jun 26, 2014 at 3:23 AM, Pádraig Brady p...@draigbrady.com wrote: -g=$(id -u $NON_ROOT_USERNAME) || framework_failure_ +u=$(id -u $NON_ROOT_USERNAME) || framework_failure_ +g=u This will work better :-) g=$u It's already pushed

RFC: Change pwd to assume -L by default

2014-06-29 Thread Pádraig Brady
POSIX says that `pwd` without options should assume -L is specified. pwd is most often invoked as a shell builtin and bash, dash, zsh, ksh all follow POSIX and assume that -L is the default. However coreutils pwd assumes -P is the default, according to this comment in the source: POSIX requires

Re: RFC: Change pwd to assume -L by default

2014-06-30 Thread Pádraig Brady
On 06/30/2014 03:40 AM, Jim Meyering wrote: On Sun, Jun 29, 2014 at 9:42 AM, Pádraig Brady p...@draigbrady.com wrote: POSIX says that `pwd` without options should assume -L is specified. pwd is most often invoked as a shell builtin and bash, dash, zsh, ksh all follow POSIX and assume that -L

Re: seq feature: print letters

2014-06-30 Thread Pádraig Brady
On 06/30/2014 11:23 AM, assafgor...@gmail.com wrote: Hello, I'd like to suggest a patch to allow seq to generate letter sequences. With this patch, 'seq' can print letters of alphabets in the current locale (or user-specified language). Examples: # print all letters in the current

Re: [PATCH 1/2] chcon: use security_check_context() for context validation

2014-06-30 Thread Pádraig Brady
On 06/30/2014 04:12 PM, Namhyung Kim wrote: It seems context_new() and _free() are used for checking validity of a specified context. The libselinux provides security_check_context for this purpose so use it. Note that context_new() can fail for a valid context - e.g. ENOMEM. *

Re: [PATCH 2/2] chcon: use specified_context directly

2014-06-30 Thread Pádraig Brady
On 06/30/2014 04:12 PM, Namhyung Kim wrote: Since it's verified by security_check_context() it can be used in change_file_context() without converting to context_t everytime. * src/chcon.c (change_file_context): Use specified_context directly. --- src/chcon.c | 16 1 file

Re: [PATCH 1/2] chcon: use security_check_context() for context validation

2014-07-01 Thread Pádraig Brady
On 06/30/2014 05:05 PM, Pádraig Brady wrote: On 06/30/2014 04:42 PM, Pádraig Brady wrote: On 06/30/2014 04:12 PM, Namhyung Kim wrote: It seems context_new() and _free() are used for checking validity of a specified context. The libselinux provides security_check_context for this purpose so

Re: RFC: Change pwd to assume -L by default

2014-07-01 Thread Pádraig Brady
On 07/01/2014 04:36 PM, Jim Meyering wrote: On Tue, Jul 1, 2014 at 8:02 AM, Jim Meyering j...@meyering.net wrote: On Mon, Jun 30, 2014 at 2:29 AM, Pádraig Brady p...@draigbrady.com wrote: I'll push the attached for the pwd change later. That looks fine. Thanks. I spoke too soon. Now

Re: test clean-up: use env kill, not $abs_top_builddir/src/kill

2014-07-01 Thread Pádraig Brady
On 07/01/2014 05:49 PM, Jim Meyering wrote: I wrote $abs_top_builddir/src/kill to ensure that we'd run the just-build coreutils binary, and not a shell built-in function by the same name -- but that was back before I discovered that env builtin is a much better way to do the job. I changed

Re: [PATCH] Fix integer cast warning on chcon.c

2014-07-02 Thread Pádraig Brady
On 07/02/2014 07:02 AM, Alex Deymo wrote: The warning was introduced yesterday on this change: http://lists.gnu.org/archive/html/coreutils/2014-07/msg2.html src/chcon.c:144:21: error: initialization makes integer from pointer without a cast Feel free to modify the patch as you wish.

Re: test clean-up: use env kill, not $abs_top_builddir/src/kill

2014-07-02 Thread Pádraig Brady
On 07/01/2014 06:32 PM, Jim Meyering wrote: On Tue, Jul 1, 2014 at 9:58 AM, Pádraig Brady p...@draigbrady.com wrote: On 07/01/2014 05:49 PM, Jim Meyering wrote: I wrote $abs_top_builddir/src/kill to ensure that we'd run the just-build coreutils binary, and not a shell built-in function

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-02 Thread Pádraig Brady
On 07/02/2014 01:44 AM, Alex Deymo wrote: Hi again, Sorry for the delay with this patch. Here is patch v7 attached. *** symlinks vs shebangs: * Other projects use symlinks to have a multicall binary; including busybox and toolbox which cover similar functionality as coreutils; but not

Re: [PATCH] maint: simplify parsing df's output in shell scripts

2014-07-03 Thread Pádraig Brady
On 07/04/2014 12:57 AM, Bernhard Voelker wrote: Avoid complicated and error-prone parsing of df's output via sed(1), cut(1), etc., and instead use df's more modern --output option. * src/ioblksize.h (in a comment): Simplify the extraction of the device name of the mounted file system from

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-04 Thread Pádraig Brady
On 07/02/2014 04:34 PM, Pádraig Brady wrote: On 07/02/2014 01:44 AM, Alex Deymo wrote: Hi again, Sorry for the delay with this patch. Here is patch v7 attached. *** symlinks vs shebangs: * Other projects use symlinks to have a multicall binary; including busybox and toolbox which cover

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-05 Thread Pádraig Brady
On 07/04/2014 05:06 PM, Pádraig Brady wrote: On 07/02/2014 04:34 PM, Pádraig Brady wrote: On 07/02/2014 01:44 AM, Alex Deymo wrote: Hi again, Sorry for the delay with this patch. Here is patch v7 attached. *** symlinks vs shebangs: * Other projects use symlinks to have a multicall binary

Re: [PATCH] true,false: avoid initialization overhead unless needed

2014-07-07 Thread Pádraig Brady
On 07/07/2014 09:48 AM, Bernhard Voelker wrote: This is a minor performance improvement: $ strace -fv /bin/true --xxx 21 | wc -l 105 $ strace -fv src/true --xxx 21 | wc -l 26 $ time for i in $(seq 1000) ; do /bin/true --xxx ; done /dev/null real0m5.083s user

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-07 Thread Pádraig Brady
On 07/07/2014 12:41 AM, Bernhard Voelker wrote: On 07/05/2014 03:40 PM, Pádraig Brady wrote: On 07/04/2014 05:06 PM, Pádraig Brady wrote: Rolled up for easy application on master: http://www.pixelbeat.org/cu/single-binary_v8.patch Thanks for squashing into one patch. Here some comments

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-08 Thread Pádraig Brady
On 07/08/2014 04:23 AM, Alex Deymo wrote: Hi! I'm back. On Mon, Jul 7, 2014 at 8:40 AM, Pádraig Brady p...@draigbrady.com mailto:p...@draigbrady.com wrote: On 07/07/2014 12:41 AM, Bernhard Voelker wrote: On 07/05/2014 03:40 PM, Pádraig Brady wrote: 15. src/coreutils

[PATCH] build: update gnulib submodule to latest

2014-07-11 Thread Pádraig Brady
* gnulib: Sync recent cleanups and the fix for missing df entries in the presence of bind mounts: http://bugs.gnu.org/17833 * NEWS: Detail the df bug fix. --- NEWS |5 + gnulib |2 +- 2 files changed, 6 insertions(+), 1 deletions(-) diff --git a/NEWS b/NEWS index 4e90b79..5a029f4

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-12 Thread Pádraig Brady
On 07/08/2014 11:50 AM, Pádraig Brady wrote: On 07/08/2014 04:23 AM, Alex Deymo wrote: Hi! I'm back. On Mon, Jul 7, 2014 at 8:40 AM, Pádraig Brady p...@draigbrady.com mailto:p...@draigbrady.com wrote: On 07/07/2014 12:41 AM, Bernhard Voelker wrote: On 07/05/2014 03:40 PM

Re: [PATCH] gettext: update macros to version 0.19

2014-07-12 Thread Pádraig Brady
On 07/12/2014 01:53 PM, Pádraig Brady wrote: On 07/12/2014 12:39 PM, Pádraig Brady wrote: On 07/11/2014 03:43 PM, Daiki Ueno wrote: Bernhard Voelker m...@bernhard-voelker.de writes: On 07/11/2014 03:13 PM, Daiki Ueno wrote: Could you provide an example of the build failures with 0.19.1

Re: [PATCH] maint: ensure Co-authored-by in commit message has an email address

2014-07-13 Thread Pádraig Brady
On 07/13/2014 03:12 PM, Bernhard Voelker wrote: Otherwise, the script gitlog-to-changelog would issue a warning during 'make dist': ./build-aux/gitlog-to-changelog --since=2008-02-08 /dev/null gitlog-to-changelog: warning: missing email address for Bernhard \ Voelker.

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-13 Thread Pádraig Brady
On 07/13/2014 01:59 PM, Bernhard Voelker wrote: On 07/12/2014 06:56 PM, Pádraig Brady wrote: Here is the complete rolled up patch, which I'm about ready to push. http://www.pixelbeat.org/cu/single-binary_v10.patch Thanks! The man pages issues are almost gone now: the only difference

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-13 Thread Pádraig Brady
On 07/13/2014 06:34 PM, Jim Meyering wrote: On Sun, Jul 13, 2014 at 7:44 AM, Pádraig Brady p...@draigbrady.com wrote: On 07/13/2014 01:59 PM, Bernhard Voelker wrote: On 07/12/2014 06:56 PM, Pádraig Brady wrote: Here is the complete rolled up patch, which I'm about ready to push. http

Re: [PATCH] gettext: update macros to version 0.19

2014-07-13 Thread Pádraig Brady
On 07/13/2014 02:19 AM, Pádraig Brady wrote: On 07/12/2014 01:53 PM, Pádraig Brady wrote: On 07/12/2014 12:39 PM, Pádraig Brady wrote: On 07/11/2014 03:43 PM, Daiki Ueno wrote: Bernhard Voelker m...@bernhard-voelker.de writes: On 07/11/2014 03:13 PM, Daiki Ueno wrote: Could you provide

[PATCH] maint: avoid an inconsequential mem leak

2014-07-13 Thread Pádraig Brady
* src/df.c (get_disk): Avoid an inconsequential mem leak spotted by coverity. --- src/df.c |6 +- 1 files changed, 5 insertions(+), 1 deletions(-) diff --git a/src/df.c b/src/df.c index 063cabf..c84716a 100644 --- a/src/df.c +++ b/src/df.c @@ -1185,7 +1185,11 @@ get_disk (char const

Re: [PATCH] df: use the last device name provided by the system

2014-07-13 Thread Pádraig Brady
On 07/13/2014 08:16 PM, Jim Meyering wrote: On Thu, May 29, 2014 at 7:45 AM, Pádraig Brady p...@draigbrady.com wrote: duplicities Might as well correct the preexisting comment typo (twice), too: s/duplicities/duplicates/ OK. The patch in this thread is already merged, but I'll merge

Re: [PATCH] gettext: update macros to version 0.19

2014-07-13 Thread Pádraig Brady
On 07/13/2014 09:50 PM, Daiki Ueno wrote: Pádraig Brady p...@draigbrady.com writes: Having realized that this update would break the continuous integration server also I've decided to revert for now, so that there is a less problematic sync point for the coreutil-8.23 release. We can

[PATCH] tests: avoid hang when files created with wrong permissions

2014-07-13 Thread Pádraig Brady
* tests/split/b-chunk.sh: Never show the rm prompt which would hang the test suite. This was seen when split erroneously created files with no persmissions, which was triggered by this compiler bug in clang 3.4: http://llvm.org/bugs/show_bug.cgi?id=18346 --- tests/split/b-chunk.sh |2 +- 1

[PATCH] maint: avoid clang -Wint-to-pointer-cast warning

2014-07-13 Thread Pádraig Brady
* src/chroot.c: Explicitly cast int to pointer type. --- src/chroot.c |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/src/chroot.c b/src/chroot.c index a623f88..fff0b53 100644 --- a/src/chroot.c +++ b/src/chroot.c @@ -116,7 +116,8 @@ parse_additional_groups (char const

[PATCH] tests: fix portability issue in new dd/ascii test

2014-07-13 Thread Pádraig Brady
* tests/dd/ascii.sh: Quote so that '\\' is passed to printf rather than a single '\', as that's not portable. bash, dash, zsh and external solaris printf were seen to support printf '\%03o' 1 2 while ksh, freebsh shell and external GNU printf need the more portable printf '\\%03o' 1 2 Note we

[PATCH] tests: fix portabilitiy issue in new od-endian test

2014-07-13 Thread Pádraig Brady
* tests/misc/od-endian.sh: '\n' is not generally supported in the replacement, so use the more portable \\$NL. --- tests/misc/od-endian.sh |7 +-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/tests/misc/od-endian.sh b/tests/misc/od-endian.sh index 5ee17e6..a01ae0a 100755

Re: [PATCH v2] build: Option for building all tools in a single binary

2014-07-13 Thread Pádraig Brady
On 07/13/2014 03:44 PM, Pádraig Brady wrote: On 07/13/2014 01:59 PM, Bernhard Voelker wrote: On 07/12/2014 06:56 PM, Pádraig Brady wrote: Here is the complete rolled up patch, which I'm about ready to push. http://www.pixelbeat.org/cu/single-binary_v10.patch Thanks! The man pages issues

Re: [PATCH] maint: avoid clang -Wint-to-pointer-cast warning

2014-07-14 Thread Pádraig Brady
On 07/14/2014 01:59 AM, Bob Proulx wrote: Pádraig Brady wrote: Subject: Re: [PATCH] maint: avoid clang -Wint-to-pointer-cast warning What was the text of the original warning? I think that would be interesting to review. I think it would provide an additional clue. It was complaining

Re: [platform-testers] new snapshot available: coreutils-8.22.151-37b36

2014-07-14 Thread Pádraig Brady
On 07/14/2014 10:38 PM, Eric Blake wrote: On 07/13/2014 08:47 PM, Pádraig Brady wrote: [umm - was the Reply-to of relavant-mailing-l...@gnu.org intentional? I'm assuming you wanted replies just to the coreutils list] That was set by the gnu mailing as I didn't set a specific reply

Re: dd statistics output

2014-07-16 Thread Pádraig Brady
On 07/16/2014 03:45 AM, Christian Groessler wrote: Hi, the final output of 'dd' is in SI mode (or how to call it). It uses 10^6 instead of 2^20 for megabyte. Example: $ dd if=/dev/zero of=/dev/null bs=65536 count=4096 4096+0 records in 4096+0 records out 268435456 bytes (268 MB)

Re: dd statistics output

2014-07-16 Thread Pádraig Brady
On 07/16/2014 10:38 AM, Pádraig Brady wrote: On 07/16/2014 03:45 AM, Christian Groessler wrote: Hi, the final output of 'dd' is in SI mode (or how to call it). It uses 10^6 instead of 2^20 for megabyte. Example: $ dd if=/dev/zero of=/dev/null bs=65536 count=4096 4096+0 records in 4096

Re: dd statistics output

2014-07-16 Thread Pádraig Brady
On 07/16/2014 11:09 PM, Christian Groessler wrote: On 07/16/14 15:42, Pádraig Brady wrote: Note another reason to _not_ apply the patch is that requests to print the statistics can come async through SIGUSR1, and thus increase the chances of inconsistent output. Sorry, I cannot follow

various results

2014-07-16 Thread Pádraig Brady
Summary from these test is that no code issues were identified. Tests could use a little work on netbsd, but not worth it for this release I think. thanks, Pádraig. POWER 7, ppc64, Fedora 18 Testsuite summary for GNU

[PATCH] tests: fix false failure in cp --preserve=context test

2014-07-18 Thread Pádraig Brady
With libselinux-2.2.1-6.fc20.x86_64, kernel-3.12.6-300.fc20.x86_64 `cp --preserve=context src dst` was seen to succeed when src and dst where on the same fixed context file system, as lsetfilecon() returned success in this case when the context wasn't being changed. * tests/cp/cp-a-selinux.sh:

Re: [PATCH] tests: fix false failure in cp --preserve=context test

2014-07-18 Thread Pádraig Brady
On 07/18/2014 03:07 PM, Bernhard Voelker wrote: On 07/18/2014 02:04 PM, Pádraig Brady wrote: * tests/cp/cp-a-selinux.sh: Copy from a different file system to most likely have a different context that will test context setting logic correctly. diff --git a/tests/cp/cp-a-selinux.sh b/tests/cp

Re: Problem compiling latest git snapshot (8.22.157-1b243)

2014-07-18 Thread Pádraig Brady
On 07/18/2014 09:09 PM, Assaf Gordon wrote: Hi, Trying to build the latest revision (in an existing 'coreutil' directory after 'git pull', not a fresh clone), ./bootstrap fails at the very end with: build-aux/gen-single-binary.sh: 52: build-aux/gen-single-binary.sh: Bad

Re: Obscure test failures on DilOS (OpenSolaris-like) with 8.22.157-1b243

2014-07-18 Thread Pádraig Brady
On 07/19/2014 01:03 AM, Assaf Gordon wrote: Hello, Few tests fail of version 8.22.157-1b243 (and I assume 8.23 now) fail on DilOS version 1.3.5.16 . (DilOS is Illumos kernel (formally OpenSolaris) with Debian-like packaging system: http://www.dilos.org/about-dilos ). The failure is

Re: [PATCH 1/2] seq: don't allow --equal-width option with infinite FIRST and LAST

2014-07-26 Thread Pádraig Brady
On 07/26/2014 07:06 PM, Bernhard Voelker wrote: seq(1) could not determine the width of large values toward INF values. Therefore, specifying -w is useless in such a case. * src/seq.c (main): Output an error diagnostic when the -w option is specified together with non-finite values for

Re: [PATCH 2/2] doc: explicitly mention 'inf' values in seq(1) documentation

2014-07-26 Thread Pádraig Brady
On 07/26/2014 07:06 PM, Bernhard Voelker wrote: * NEWS (seq invocation): Explicitly mention 'infinity' as possible values for the program arguments. --- doc/coreutils.texi | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/doc/coreutils.texi b/doc/coreutils.texi index

Re: [PATCH 2/2] doc: explicitly mention 'inf' values in seq(1) documentation

2014-07-29 Thread Pádraig Brady
On 07/29/2014 02:25 PM, Bernhard Voelker wrote: On 07/26/2014 10:34 PM, Pádraig Brady wrote: On 07/26/2014 07:06 PM, Bernhard Voelker wrote: * NEWS (seq invocation): Explicitly mention 'infinity' as possible values for the program arguments. Perhaps s/infinity/inf/ as per http

Re: [platform-testers] new snapshot available: coreutils-8.22.151-37b36

2014-07-31 Thread Pádraig Brady
On 07/30/2014 09:48 PM, Eric Blake wrote: On 07/14/2014 10:04 PM, Eric Blake wrote: On 07/14/2014 07:33 PM, Pádraig Brady wrote: On 32-bit cygwin, a default ./configure didn't even get to 'make check' due to this error: CCLD src/make-prime-list.exe make[2]: *** No rule to make target

Re: expr won't match empty strings

2014-08-02 Thread Pádraig Brady
On 08/02/2014 06:03 AM, Luke Kendall wrote: I'm hesitant to report this, but I think it's an actual bug in expr that's been there from day one. I believe that expr, when used to match regular expressions, should use the success/failure of the pattern match to determine the exit code.

Re: script suggestion: 'check_program' to easily run multiple tests

2014-08-04 Thread Pádraig Brady
On 08/03/2014 10:57 PM, Bernhard Voelker wrote: On 08/02/2014 12:49 AM, Assaf Gordon wrote: Attached is a patch that adds a 'makefile' target to test a program. Examples: make check-prog T=sort make check-very-expensive-prog T=tail Thanks for picking this up again. diff

Re: My experience with using cp to copy a lot of files (432 millions, 39 TB)

2014-08-11 Thread Pádraig Brady
On 08/11/2014 02:55 PM, Rasmus Borup Hansen wrote: [lots of impressive analysis snipped] I hope this can help or at least be interesting for someone. Info like this is hard to come by and very important. I'll apply the attached in your name. (I'll add a link to the archives to the commit when

[PATCH] df: improve mount point selection with inaccurate mount list

2014-08-18 Thread Pádraig Brady
v8.23 has a test failure on Fedora rawhide build servers in tests/df/skip-duplicate.sh. This was due to no '/' entry being output by df. That was due to an inaccurate /proc/mounts on the build environment as stat(/mnt/point) identified all these /proc/mounts entries as having the same device id:

Re: df: use mountinfo from /proc on Linux

2014-08-20 Thread Pádraig Brady
On 08/20/2014 03:53 PM, Fridolin Pokorny wrote: Hi, I am about to implement /proc/self/mountinfo support for df. This feature is marked as TODO in sources. I have found a suitable parser provided by libmount from util-linux [1]. This could be the best option here in my opinion. The

Re: My experience with using cp to copy a lot of files (432 millions, 39 TB)

2014-08-21 Thread Pádraig Brady
On 08/21/2014 08:10 AM, Bernhard Voelker wrote: On 08/11/2014 03:55 PM, Rasmus Borup Hansen wrote: Trusting that resizing the hash table would eventually finish, the cp command was allowed to continue, and after a while it started copying again. It stopped again and resized the hash table a

Re: [PATCH] ls: Add check_env_quoting() function

2014-08-21 Thread Pádraig Brady
On 08/21/2014 09:09 PM, Yurij Goncharuk wrote: Hello! I still research code from 'coreutils' and find place where put some benefits. I offer replace block for setting quoting style(watching environment variable QUOTING_STYLE) with function as comment 'FIXME: put this in a function.' in

[PATCH] maint: include libstdbuf.c in extraneous headers check

2014-08-22 Thread Pádraig Brady
* cfg.mk (sc_system_h_headers): Don't exclude libstdbuf.c. * src/libstdbuf.c: Remove headers already included in system.h. --- cfg.mk |2 +- src/libstdbuf.c |2 -- 2 files changed, 1 insertions(+), 3 deletions(-) diff --git a/cfg.mk b/cfg.mk index 26a5966..3ac1504 100644 ---

Re: [PATCH] mv: add --reflink to affect fallback copy

2014-09-02 Thread Pádraig Brady
On 07/22/2014 05:50 PM, David Sterba wrote: On some filesystems (btrfs), moving a file within the filesystem may cross subvolume boundaries and we can use the lightweight reflink copy, similar to what cp(1) does. This is typically faster than full file copy. Default mode is unchanged. *

<    5   6   7   8   9   10   11   12   13   14   >