Add casts, to avoid warnings.
[gnulib.git] / lib / pipe.c
index d44f62e..f8e7dee 100644 (file)
@@ -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)