mirror of
https://github.com/valinet/ExplorerPatcher.git
synced 2024-11-24 07:30:22 +01:00
Closed handles when ShellExecuteExW with SEE_MASK_NOCLOSEPROCESS
This commit is contained in:
parent
8cba312707
commit
abf0d38cb4
@ -974,6 +974,7 @@ static BOOL GUI_Build(HDC hDC, HWND hwnd, POINT pt)
|
||||
{
|
||||
|
||||
}
|
||||
CloseHandle(sei.hProcess);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -431,6 +431,7 @@ int WINAPI wWinMain(
|
||||
DWORD dwExitCode = 0;
|
||||
GetExitCodeProcess(sei.hProcess, &dwExitCode);
|
||||
SetLastError(dwExitCode);
|
||||
CloseHandle(sei.hProcess);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -61,6 +61,7 @@ int main(int argc, char** argv)
|
||||
WaitForSingleObject(ShExecInfo.hProcess, INFINITE);
|
||||
DWORD dwExitCode = 0;
|
||||
GetExitCodeProcess(ShExecInfo.hProcess, &dwExitCode);
|
||||
CloseHandle(ShExecInfo.hProcess);
|
||||
return dwExitCode;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user