wshom.ocx: Actually wait for process termination in IWshShell3::Run().

Signed-off-by: Dmitry Timoshkov <dmitry@baikal.ru>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Dmitry Timoshkov 2019-10-07 12:59:40 +08:00 committed by Alexandre Julliard
parent 6c8cb0abac
commit 57961e5e78
1 changed files with 1 additions and 0 deletions

View File

@ -1297,6 +1297,7 @@ static HRESULT WINAPI WshShell3_Run(IWshShell3 *iface, BSTR cmd, VARIANT *style,
{
if (waitforprocess)
{
WaitForSingleObject(info.hProcess, INFINITE);
GetExitCodeProcess(info.hProcess, exit_code);
CloseHandle(info.hProcess);
}