堆分配被泄露,Application Verifier / WinDbg

时间:2016-08-30 22:55:09

标签: memory-leaks windbg application-verifier

我正在使用Application Verifier和WinDbg调试可执行文件。我在“基础知识”下打开了“泄漏”测试。我的问题是,当Application Verifier发现泄漏时,它似乎进入某种抛出异常的无限循环。我收到这样的错误:

Button btn = new Button();
//in this situation text color it will be black, for white 255,255,255
btn.Forecolor = System.Drawing.Color.FromArgb(0,0,0);

但是当我按======================================= VERIFIER STOP 0000000000000900: pid 0x1FE0: A heap allocation was leaked. 00000000155A6FF0 : Address of the leaked allocation. Run !heap -p -a <address> to get additional information about the allocation. 0000000000571BE0 : Address to the allocation stack trace. Run dps <address> to view the allocation stack. 0000000012314FD8 : Address of the owner dll name. Run du <address> to read the dll name. 000007FEF8460000 : Base of the owner dll. Run .reload <dll_name> = <address> to reload the owner dll. Use 'lm' to get more information about the loaded and unloaded modules. ======================================= 继续调试时,我再次得到完全相同的消息(一次又一次),只是地址信息略有不同。

为什么会这样?有没有办法忽略这个泄漏而不完全关闭泄漏检查?按照目前的情况,我无法运行我的程序来完成测试其他问题,因为Application Verifier会在此漏洞上“挂起”。

0 个答案:

没有答案