Shutdown logging before Environment.Exit.

pull/2250/head
Taloth Saldono 7 years ago
parent ea5769fdd6
commit e01e822394

@ -57,7 +57,7 @@ namespace NzbDrone.Console
private static void Exit(ExitCodes exitCode) private static void Exit(ExitCodes exitCode)
{ {
LogManager.Flush(); LogManager.Shutdown();
if (exitCode != ExitCodes.Normal) if (exitCode != ExitCodes.Normal)
{ {
@ -80,8 +80,6 @@ namespace NzbDrone.Console
System.Console.ReadLine(); System.Console.ReadLine();
} }
//Need this to terminate on mono (thanks nlog)
LogManager.Configuration = null;
Environment.Exit((int)exitCode); Environment.Exit((int)exitCode);
} }
} }

Loading…
Cancel
Save