X-Git-Url: http://git.csclub.uwaterloo.ca/?p=kopensolaris-gnu%2Fglibc.git;a=blobdiff_plain;f=posix%2Fexecle.c;h=a36d49a407e8263bd44797909e3fe594a8a897e9;hp=a211b24b77d0d9920a60a0111cc5957edf3c29f3;hb=5533aabe82b395821715228b1d791a2dd4388190;hpb=946ceb16e87eed8b210657dae85d2ed9515821c5 diff --git a/posix/execle.c b/posix/execle.c index a211b24b77..a36d49a407 100644 --- a/posix/execle.c +++ b/posix/execle.c @@ -24,14 +24,15 @@ Cambridge, MA 02139, USA. */ /* Execute PATH with all arguments after PATH until a NULL pointer, and the argument after that for environment. */ int -DEFUN(execle, (path), CONST char *path DOTS) +DEFUN(execle, (path), CONST char *path AND CONST char *arg DOTS) { CONST char *argv[1024], *CONST *envp; register unsigned int i; va_list args; - va_start(args, path); - i = 0; + va_start(args, arg); + argv[0] = arg; + i = 1; do { argv[i] = va_arg(args, CONST char *);