View | Details | Raw Unified | Return to bug 199976
Collapse All | Expand All

(-)xargs.1 (-1 / +5 lines)
Lines 206-212 Link Here
206
.Ar maxprocs
206
.Ar maxprocs
207
invocations of
207
invocations of
208
.Ar utility
208
.Ar utility
209
at once.
209
at once. If
210
.Ar maxprocs
211
is negative or 0,
212
.Nm
213
will run as many processes as possible at a time.
210
.It Fl p
214
.It Fl p
211
Echo each command to be executed and ask the user whether it should be
215
Echo each command to be executed and ask the user whether it should be
212
executed.
216
executed.
(-)xargs.c (-2 / +5 lines)
Lines 159-166 Link Here
159
			oflag = 1;
159
			oflag = 1;
160
			break;
160
			break;
161
		case 'P':
161
		case 'P':
162
			if ((maxprocs = atoi(optarg)) <= 0)
162
			maxprocs = strtol(optarg, &endptr, 10);
163
				errx(1, "max. processes must be >0");
163
			if (*endptr != '\0')
164
				errx(1, "max. processes must be a number");
165
			if (maxprocs < 1)
166
				maxprocs = nargs;
164
			break;
167
			break;
165
		case 'p':
168
		case 'p':
166
			pflag = 1;
169
			pflag = 1;

Return to bug 199976