On Friday 28 March 2008 11:05, Sam Clemens wrote:
Randall R Schulz wrote:
On Friday 28 March 2008 01:23, Wolfgang Woehl wrote:
Randall R Schulz:
There's no way for xargs to know about anything other than the kernel-imposed argument list size limit.
Where can I read the argument list size limit? I fail to see anything relevant with ulimit -a or in proc or in pam's limits.conf.
% egrep ARG_MAX /usr/include/linux/limits.h #define ARG_MAX 131072 /* # bytes of args + environ for exec() */
And I believe there's also a maximum size to the number of pointers in the array char *argv[].
I only know how it was implemented in the old (very old) days, but the representation of the arguments + environment was simply as a blob of bytes with NUL bytes deliminting individual arguments and a pointer marking the end of the arguments and the beginning of the environment. The vectors of argument and environment value pointers was reconstituted in the user mode code on the "other side" of the exec call. If that's still the scheme being used, then it doesn't matter how many individual arguments and environment variables there are, just the number of bytes it takes to hold them all (including the delimiting / separating NULs). Randall Schulz -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org For additional commands, e-mail: opensuse+help@opensuse.org