From 956992ff71b33151c82a970d3b9aaae1ec9590fc Mon Sep 17 00:00:00 2001 From: James Youngman Date: Fri, 16 Dec 2005 08:34:41 +0000 Subject: [PATCH] Fixed bug# 15211, that xargs --show-limits is not documented in the manpage or in the usage message --- xargs/xargs.1 | 18 ++++++++++++++++-- xargs/xargs.c | 2 +- 2 files changed, 17 insertions(+), 3 deletions(-) diff --git a/xargs/xargs.1 b/xargs/xargs.1 index c4872697..edbc4f68 100644 --- a/xargs/xargs.1 +++ b/xargs/xargs.1 @@ -8,8 +8,8 @@ xargs \- build and execute command lines from standard input [\-I replace-str] [\-i[replace-str]] [\-\-replace[=replace-str]] [\-l[max-lines]] [\-L max-lines] [\-\-max\-lines[=max-lines]] [\-n max-args] [\-\-max\-args=max-args] [\-s max-chars] [\-\-max\-chars=max-chars] [\-P max-procs] [\-\-max\-procs=max-procs] -[\-\-interactive] [\-\-verbose] [\-\-exit] -[\-\-no\-run\-if\-empty] [\-\-arg\-file=file] [\-\-version] [\-\-help] +[\-\-interactive] [\-\-verbose] [\-\-exit] [\-\-no\-run\-if\-empty] +[\-\-arg\-file=file] [\-\-show\-limits] [\-\-version] [\-\-help] [command [initial-arguments]] .SH DESCRIPTION This manual page @@ -151,6 +151,20 @@ Print the version number of .B xargs and exit. .TP +.I "\-\-show\\-limits" +Display the limits on the command-line length which are imposed by the +operating system, +.BR xargs ' +choice of buffer size and the +.I \-s +option. Pipe the input from +.B /dev/null +(and perhaps specify +.BR --no-run-if-empty ) +if you don't want +.B xargs +to do anything. +.TP .I "\-\-exit, \-x" Exit if the size (see the \fI\-s\fR option) is exceeded. .TP diff --git a/xargs/xargs.c b/xargs/xargs.c index 3eba3662..5bd71f93 100644 --- a/xargs/xargs.c +++ b/xargs/xargs.c @@ -1244,7 +1244,7 @@ Usage: %s [-0prtx] [--interactive] [--null] [-d|--delimiter=delim]\n\ [-I replace-str] [-i[replace-str]] [--replace[=replace-str]]\n\ [-n max-args] [--max-args=max-args]\n\ [-s max-chars] [--max-chars=max-chars]\n\ - [-P max-procs] [--max-procs=max-procs]\n\ + [-P max-procs] [--max-procs=max-procs] [[--show-limits]\n\ [--verbose] [--exit] [--no-run-if-empty] [--arg-file=file]\n\ [--version] [--help] [command [initial-arguments]]\n"), program_name);