Unverified Commit e6b45f93 authored by Michael Snoyman's avatar Michael Snoyman Committed by GitHub

Merge pull request #160 from Mistuke/dont-exit-when-event-isnt-ours

Don't exit when even isn't ours
parents 6f957bca f8256f96
......@@ -903,8 +903,11 @@ waitForJobCompletion ( HANDLE hJob, HANDLE ioPort, DWORD timeout, int *pExitCode
// List of events we can listen to:
// https://msdn.microsoft.com/en-us/library/windows/desktop/ms684141(v=vs.85).aspx
while (GetQueuedCompletionStatus (ioPort, &CompletionCode,
&CompletionKey, &Overlapped, timeout)
&& (HANDLE)CompletionKey == hJob) {
&CompletionKey, &Overlapped, timeout)) {
// If event wasn't meant of us, keep listening.
if ((HANDLE)CompletionKey != hJob)
switch (CompletionCode)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment