转储 Windows 进程的句柄以及有关它们的额外信息
今天,我的应用程序在分配图像时在 Windows 上抛出“不再处理”错误。为了调试这个,我希望获得我的应用程序已获取的所有句柄的列表。如果可能的话,甚至使用类型,如字体、图像或其他内容,并将信息包含在我的错误报告中,以查看我的应用程序泄漏的位置。
我使用 Java 和 SWT,但在这种情况下调用本机函数或第三方应用程序来获取信息没有问题。
today my application throw a "no more handles" error on Windows, while allocating an image. To debug this I would love to get a list of all handles my application has aquired. If possible even with type, like font, image or whatever, and include the information in my error report to see where my application leaks.
I use Java and SWT, but have no problem with calling native functions or a third-party application to fetch the information in this case.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
对于实用程序,请尝试 Microsoft Sysinternals 中的 Process Explorer。这将显示进程字符串、句柄、文件、父进程、线程、线程堆栈等。
For a utility, try Process Explorer from Microsoft Sysinternals. This will show process strings, handles, files, parents, threads, thread stacks, etc., etc.
GDIView 是我需要的工具!它甚至可以编写脚本,因此输出可以在错误报告中使用。
GDIView was the tool I needed! It is even scriptable, so the output can be used in bug reports.