Add always logging unhandled c# exception

#1861
This commit is contained in:
Wojtek Figat
2023-11-06 12:23:17 +01:00
parent f703e7de77
commit a0d4714a0f

View File

@@ -135,13 +135,10 @@ namespace FlaxEngine
{
if (e.ExceptionObject is Exception exception)
{
Debug.LogError($"Unhandled Exception: {exception.Message}");
Debug.LogException(exception);
if (e.IsTerminating && !System.Diagnostics.Debugger.IsAttached)
Platform.Fatal($"Unhandled Exception: {exception}");
else
{
Debug.LogError($"Unhandled Exception: {exception.Message}");
Debug.LogException(exception);
}
}
}