-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Per POSIX, cygwin 1.5 omits ARG_MAX to mean that the limit is greater than the minimum, but otherwise unspecified. Committing this as trivial to allow compilation of the master branch. The 4.4.x branch was immune, as this was introduced during Leslie's patches.
- -- Don't work too hard, make some time for fun as well! Eric Blake [email protected] -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (Cygwin) Comment: Public key at home.comcast.net/~ericblake/eblake.gpg Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iEYEARECAAYFAkoJbZkACgkQ84KuGfSFAYDfMwCdFvNDTyIsERFM3s6pna8gz91c f0cAnjkK9YMDg30UUy0pPpz3IttTwtL8 =lpmx -----END PGP SIGNATURE-----
>From eef6b9b0d8a85203da5319cf7200e41e427858c2 Mon Sep 17 00:00:00 2001 From: Eric Blake <[email protected]> Date: Tue, 12 May 2009 06:35:50 -0600 Subject: [PATCH] xargs: fix compilation on cygwin * xargs/xargs.c (main): Check that ARG_MAX is defined. Signed-off-by: Eric Blake <[email protected]> --- ChangeLog | 3 +++ xargs/xargs.c | 2 ++ 2 files changed, 5 insertions(+), 0 deletions(-) diff --git a/ChangeLog b/ChangeLog index d22984d..260dea5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2009-05-12 Eric Blake <[email protected]> + xargs: fix compilation on cygwin + * xargs/xargs.c (main): Check that ARG_MAX is defined. + xargs: avoid compiler warning * xargs/xargs.c (get_char_oct_or_hex_escape): Pass correct type to ctype macro. diff --git a/xargs/xargs.c b/xargs/xargs.c index 48b1cc0..fb97696 100644 --- a/xargs/xargs.c +++ b/xargs/xargs.c @@ -438,7 +438,9 @@ main (int argc, char **argv) * specifies that it shall be at least LINE_MAX. */ long val; +#ifdef ARG_MAX assert(bc_ctl.arg_max <= (ARG_MAX-2048)); +#endif #ifdef _SC_ARG_MAX val = sysconf(_SC_ARG_MAX); if (val > 0) -- 1.6.3.rc3.2.g4b51
_______________________________________________ Findutils-patches mailing list [email protected] http://lists.gnu.org/mailman/listinfo/findutils-patches
