diff options
Diffstat (limited to 'compat')
-rw-r--r-- | compat/mingw.c | 6 | ||||
-rw-r--r-- | compat/mingw.h | 4 |
2 files changed, 6 insertions, 4 deletions
diff --git a/compat/mingw.c b/compat/mingw.c index a0ac487c0c..afc892d6b1 100644 --- a/compat/mingw.c +++ b/compat/mingw.c @@ -1003,7 +1003,7 @@ static void mingw_execve(const char *cmd, char *const *argv, char *const *env) } } -void mingw_execvp(const char *cmd, char *const *argv) +int mingw_execvp(const char *cmd, char *const *argv) { char **path = get_path_split(); char *prog = path_lookup(cmd, path, 0); @@ -1015,11 +1015,13 @@ void mingw_execvp(const char *cmd, char *const *argv) errno = ENOENT; free_path_split(path); + return -1; } -void mingw_execv(const char *cmd, char *const *argv) +int mingw_execv(const char *cmd, char *const *argv) { mingw_execve(cmd, argv, environ); + return -1; } int mingw_kill(pid_t pid, int sig) diff --git a/compat/mingw.h b/compat/mingw.h index 0ff1e04812..ef5b15014e 100644 --- a/compat/mingw.h +++ b/compat/mingw.h @@ -274,9 +274,9 @@ int mingw_utime(const char *file_name, const struct utimbuf *times); pid_t mingw_spawnvpe(const char *cmd, const char **argv, char **env, const char *dir, int fhin, int fhout, int fherr); -void mingw_execvp(const char *cmd, char *const *argv); +int mingw_execvp(const char *cmd, char *const *argv); #define execvp mingw_execvp -void mingw_execv(const char *cmd, char *const *argv); +int mingw_execv(const char *cmd, char *const *argv); #define execv mingw_execv static inline unsigned int git_ntohl(unsigned int x) |