I am developing a .Net 2.0 application in which a StackOverflowException occurs. Is there a way to print/log the stack trace before/during the application aborts? This is a long running server-side process which would be hard to execute under a debugger. I know that StackOverflowException can not be caught.
-
Does it generate a crash dump when it crashes? If so this might help blogs.msdn.com/tess/archive/2008/03/31/…Martin Smith– Martin Smith2010-04-07 09:58:05 +00:00Commented Apr 7, 2010 at 9:58
-
Also you don't say what kind of application. If it is a web application I think you need to use the IIS Debug toolkit (although I don't know about IIS7)Martin Smith– Martin Smith2010-04-07 10:38:31 +00:00Commented Apr 7, 2010 at 10:38
Add a comment
|
1 Answer
Use ADPlus (from Windows Debugging Tools) to force a dump on crash.
E.g.
adplus -hang -pn <process name> -o <dump file>
1 Comment
Richard
CW: Feel free to expand this with specifics (which I don't have to hand). While this doesn't cover the "before the application aborts" criterion, I don't think that is possible.