mirror of
https://github.com/ayufan/steam-deck-tools.git
synced 2026-02-09 00:54:34 +01:00
Support AbandonedMutexException in RunOnce
This commit is contained in:
parent
10a8598b82
commit
288910316f
|
|
@ -150,9 +150,16 @@ namespace CommonHelpers
|
|||
{
|
||||
runOnceMutex = TryCreateOrOpenExistingMutex(mutexName);
|
||||
|
||||
if (!runOnceMutex.WaitOne(runOnceTimeout))
|
||||
try
|
||||
{
|
||||
Fatal(title, "Run many times");
|
||||
if (!runOnceMutex.WaitOne(runOnceTimeout))
|
||||
{
|
||||
Fatal(title, "Run many times");
|
||||
}
|
||||
}
|
||||
catch (AbandonedMutexException)
|
||||
{
|
||||
// it is still OK
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue