From b79e38dcf193022b6809ef54fbca51fee9a4f7df Mon Sep 17 00:00:00 2001 From: Amir Pourmand Date: Sun, 28 Jul 2019 12:43:45 +0430 Subject: [PATCH] catching all Exceptions! --- ShareX/Program.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/ShareX/Program.cs b/ShareX/Program.cs index 12a790b52..c26b2e2c9 100644 --- a/ShareX/Program.cs +++ b/ShareX/Program.cs @@ -237,6 +237,7 @@ private static void Main(string[] args) #if !DEBUG // Allow Visual Studio to break on exceptions in Debug builds. Application.ThreadException += Application_ThreadException; AppDomain.CurrentDomain.UnhandledException += CurrentDomain_UnhandledException; + Application.SetUnhandledExceptionMode(UnhandledExceptionMode.CatchException); #endif StartTimer = Stopwatch.StartNew(); // For be able to show startup time