aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/w32proc.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/src/w32proc.c b/src/w32proc.c
index ffd5f0d0a1a..71bd28d3c24 100644
--- a/src/w32proc.c
+++ b/src/w32proc.c
@@ -1492,12 +1492,17 @@ waitpid (pid_t pid, int *status, int options)
1492 } 1492 }
1493 if (retval == STILL_ACTIVE) 1493 if (retval == STILL_ACTIVE)
1494 { 1494 {
1495 /* Should never happen. */ 1495 /* Should never happen. But it does, with invoking git-gui.exe
1496 asynchronously. So we punt, and just report this process as
1497 exited with exit code 259, when we are called with WNOHANG
1498 from child_status_changed, because in that case we already
1499 _know_ the process has died. */
1496 DebPrint (("Wait.WaitForMultipleObjects returned an active process\n")); 1500 DebPrint (("Wait.WaitForMultipleObjects returned an active process\n"));
1497 if (pid > 0 && dont_wait) 1501 if (!(pid > 0 && dont_wait))
1498 return 0; 1502 {
1499 errno = EINVAL; 1503 errno = EINVAL;
1500 return -1; 1504 return -1;
1505 }
1501 } 1506 }
1502 1507
1503 /* Massage the exit code from the process to match the format expected 1508 /* Massage the exit code from the process to match the format expected