mirror of
https://github.com/crskycode/GARbro.git
synced 2024-12-24 20:04:13 +08:00
added logging of unhandled exceptions in DEBUG build.
This commit is contained in:
parent
63bb1995ef
commit
a9375e777e
@ -67,6 +67,12 @@ namespace GARbro.GUI
|
|||||||
Trace.AutoFlush = true;
|
Trace.AutoFlush = true;
|
||||||
#endif
|
#endif
|
||||||
Trace.WriteLine ("ApplicationStartup --------------------------------", "GARbro.GUI.App");
|
Trace.WriteLine ("ApplicationStartup --------------------------------", "GARbro.GUI.App");
|
||||||
|
this.DispatcherUnhandledException += (s, args) =>
|
||||||
|
{
|
||||||
|
Trace.WriteLine (string.Format ("Unhandled exception caught: {1}", args.Exception.Message),
|
||||||
|
"GARbro.GUI.App");
|
||||||
|
Trace.WriteLine (args.Exception.StackTrace, "Stack trace");
|
||||||
|
};
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (0 != e.Args.Length)
|
if (0 != e.Args.Length)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user