mirror of
https://github.com/ShareX/ShareX.git
synced 2024-09-30 01:07:21 +13:00
Merge pull request #4298 from pourmand1376/catch_all_exceptions
catching all Exceptions!
This commit is contained in:
commit
9e04fcf4bc
1 changed files with 1 additions and 0 deletions
|
@ -237,6 +237,7 @@ private static void Main(string[] args)
|
||||||
#if !DEBUG // Allow Visual Studio to break on exceptions in Debug builds.
|
#if !DEBUG // Allow Visual Studio to break on exceptions in Debug builds.
|
||||||
Application.ThreadException += Application_ThreadException;
|
Application.ThreadException += Application_ThreadException;
|
||||||
AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
|
AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException;
|
||||||
|
Application.SetUnhandledExceptionMode(UnhandledExceptionMode.CatchException);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
StartTimer = Stopwatch.StartNew(); // For be able to show startup time
|
StartTimer = Stopwatch.StartNew(); // For be able to show startup time
|
||||||
|
|
Loading…
Reference in a new issue