1
0
mirror of https://github.com/chylex/Minecraft-Phantom-Panel.git synced 2025-04-22 19:15:48 +02:00

Catch "The pipe is being closed" Windows exception when stopping instance

This commit is contained in:
chylex 2024-03-30 07:05:59 +01:00
parent 72ddaf91ad
commit 9fcc3c53fc
Signed by: chylex
GPG Key ID: 4DE42C8F19A80548

View File

@ -75,6 +75,8 @@ static class InstanceStopProcedure {
// Ignore.
} catch (ObjectDisposedException e) when (e.ObjectName == typeof(Process).FullName && process.HasEnded) {
// Ignore.
} catch (IOException e) when (e.HResult == -2147024664 /* The pipe is being closed */) {
// Ignore.
} catch (Exception e) {
context.Logger.Warning(e, "Caught exception while sending stop command.");
}