mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2026-01-01 06:00:46 +00:00
Avoid ASF crash in #1283
Won't solve the misconfiguration caused by the user, but ASF crash can be avoided at this stage.
This commit is contained in:
@@ -100,13 +100,14 @@ namespace ArchiSteamFarm.IPC {
|
||||
Logging.InitHistoryLogger();
|
||||
|
||||
// Start the server
|
||||
IWebHost kestrelWebHost = builder.Build();
|
||||
IWebHost kestrelWebHost = null;
|
||||
|
||||
try {
|
||||
kestrelWebHost = builder.Build();
|
||||
await kestrelWebHost.StartAsync().ConfigureAwait(false);
|
||||
} catch (Exception e) {
|
||||
ASF.ArchiLogger.LogGenericException(e);
|
||||
kestrelWebHost.Dispose();
|
||||
kestrelWebHost?.Dispose();
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user