Terminate the array of execv(3) pointers by a NULL pointer in the edge case.

PR:		bin/30913
Submitted by:	Dimitri Lommers <dimitri@hinttech.com>
This commit is contained in:
ru 2001-10-04 09:02:10 +00:00
parent c0b2544ae9
commit ab0674a1b6

View File

@ -161,8 +161,10 @@ main(argc, argv)
av[1] = "-l";
comp = &av[0];
}
else if (++ap == av + ENTRIES)
else if (++ap == av + ENTRIES) {
*ap = NULL;
break;
}
lp = NULL;
}