Wait for previous process to terminate
The new process will not have read/write access to config files if it does not wait until previous processes have been terminated.
This commit is contained in:
parent
e541998629
commit
cd17e986d4
|
@ -107,6 +107,7 @@ bool pjutil::TerminatedExistingExe()
|
||||||
if (TerminateProcess(hHandle, 0))
|
if (TerminateProcess(hHandle, 0))
|
||||||
{
|
{
|
||||||
bTerminated = true;
|
bTerminated = true;
|
||||||
|
WaitForSingleObject(hHandle, 30 * 1000);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue