mirror of
https://github.com/moonlight-stream/GS-IPv6-Forwarder.git
synced 2025-06-30 23:05:34 +00:00
Fix crash when toggling GameStream on
This commit is contained in:
parent
4c94ecfce1
commit
e0db902f7d
@ -1007,9 +1007,14 @@ int Run(bool standaloneExe)
|
||||
switch (WaitForMultipleObjects(2, objects, FALSE, 120 * 1000)) {
|
||||
case WAIT_OBJECT_0:
|
||||
// Interface state changed. Update pinholes immediately.
|
||||
ResetLogFile(standaloneExe);
|
||||
printf("Woke up for network interface change\n");
|
||||
break;
|
||||
case WAIT_OBJECT_0 + 1:
|
||||
// GameStream state changed
|
||||
ResetLogFile(standaloneExe);
|
||||
printf("Woke up for GameStream state change\n");
|
||||
|
||||
ResetEvent(gameStreamStateChangeEvent);
|
||||
|
||||
// Shutdown all relay sockets to trigger the relay threads to terminate.
|
||||
@ -1039,12 +1044,13 @@ int Run(bool standaloneExe)
|
||||
break;
|
||||
case WAIT_TIMEOUT:
|
||||
// Time to refresh the pinholes
|
||||
ResetLogFile(standaloneExe);
|
||||
printf("Woke up on refresh timer\n");
|
||||
break;
|
||||
case WAIT_FAILED:
|
||||
return -1;
|
||||
}
|
||||
|
||||
ResetLogFile(standaloneExe);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user