]> rtime.felk.cvut.cz Git - git.git/blobdiff - run-command.c
Test for WIN32 instead of __MINGW32_
[git.git] / run-command.c
index bb76750cd063a05483856f1f744f79c04ed80352..cf2d8f7fae1356e50736cb9d599625df79738a2a 100644 (file)
@@ -75,7 +75,7 @@ fail_pipe:
 
        trace_argv_printf(cmd->argv, "trace: run_command:");
 
-#ifndef __MINGW32__
+#ifndef WIN32
        fflush(NULL);
        cmd->pid = fork();
        if (!cmd->pid) {
@@ -315,7 +315,7 @@ int run_command_v_opt_cd_env(const char **argv, int opt, const char *dir, const
        return run_command(&cmd);
 }
 
-#ifdef __MINGW32__
+#ifdef WIN32
 static unsigned __stdcall run_thread(void *data)
 {
        struct async *async = data;
@@ -331,7 +331,7 @@ int start_async(struct async *async)
                return error("cannot create pipe: %s", strerror(errno));
        async->out = pipe_out[0];
 
-#ifndef __MINGW32__
+#ifndef WIN32
        /* Flush stdio before fork() to avoid cloning buffers */
        fflush(NULL);
 
@@ -360,7 +360,7 @@ int start_async(struct async *async)
 
 int finish_async(struct async *async)
 {
-#ifndef __MINGW32__
+#ifndef WIN32
        int ret = wait_or_whine(async->pid, "child process", 0);
 #else
        DWORD ret = 0;