如何打印StackOverflowException的堆栈跟踪 [英] How to print stack trace of StackOverflowException
本文介绍了如何打印StackOverflowException的堆栈跟踪的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我开发,其中一StackOverflowException发生的.Net 2.0应用程序。有没有一种方法来在应用程序中止前/打印/日志堆栈跟踪? 这是一个长期运行的服务器端的过程,将很难在调试器来执行。 我知道,StackOverflowException不能被抓住了。
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.
推荐答案
使用ADPlus的(从Windows调试工具),以迫使崩溃转储。
Use ADPlus (from Windows Debugging Tools) to force a dump on crash.
例如。
adplus -hang -pn <process name> -o <dump file>
这篇关于如何打印StackOverflowException的堆栈跟踪的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文