X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fpipe.c;h=f8e7dee104e9897be8bdfd2976cb3d321376d52b;hb=fa3486514bd8f15f8eb4c49821d0356b52e5a335;hp=d44f62e5fde24ef1366509188b7c23e65ca3862e;hpb=d629f6d28665184cf8970b691e48ea2dfccfa25f;p=gnulib.git diff --git a/lib/pipe.c b/lib/pipe.c index d44f62e5f..f8e7dee10 100644 --- a/lib/pipe.c +++ b/lib/pipe.c @@ -195,14 +195,16 @@ create_pipe (const char *progname, copy of the environment block - ignoring the effects of putenv() and [un]setenv(). */ { - child = spawnvpe (P_NOWAIT, prog_path, prog_argv, environ); + child = spawnvpe (P_NOWAIT, prog_path, (const char **) prog_argv, + (const char **) environ); if (child < 0 && errno == ENOEXEC) { /* prog is not an native executable. Try to execute it as a shell script. Note that prepare_spawn() has already prepended a hidden element "sh.exe" to prog_argv. */ --prog_argv; - child = spawnvpe (P_NOWAIT, prog_argv[0], prog_argv, environ); + child = spawnvpe (P_NOWAIT, prog_argv[0], (const char **) prog_argv, + (const char **) environ); } } if (stdinfd >= 0)