Delphi – FastMMDXE2在调试器使用时如何仅报告问题?
- 内容介绍
- 文章标签
- 相关推荐
本文共计331个文字,预计阅读时间需要2分钟。
我正在尝试使用FastMM版本4.99(根据FastMM4.pas顶部的评论)。我遵循了说明,使用了堆栈跟踪的完整调试模式,并在IDE调试器下运行我的.exe时发现了泄漏。例如,但当我尝试从命令行运行时,发现泄漏。
我正在尝试使用FastMM版本4.99(根据FastMM4.pas顶部的评论).我有 followed the instructions使用堆栈跟踪的完全调试模式,并且当我在IDE调试器下运行我的.exe时发现泄漏.例如但是当我尝试从命令提示符运行可执行文件,或者双击Windows资源管理器时,我没有报告泄漏. UnicodeString泄漏可能是假的,但我确信TIniFile泄漏是真实的.不使用调试器时,如何使FastMM报告/日志泄漏?
更新:此项目还使用madExcept 3.0n:.dpr文件确实将FastMM4作为其uses子句中的第一项.还有什么需要让这两者共存?
您尚未正确配置FastMM4Options.inc.从分发版本4.97的文件开始,它位于第405行:{Set this option to require the presence of the Delphi IDE to report memory leaks. This option has no effect if the option "EnableMemoryLeakReporting" is not also set.} {.$define RequireIDEPresenceForLeakReporting}
确保.在最后一行(在$define之前)并重建您的项目.
@wades发现还有另一个设置,紧接着我提到的设置,RequireDebuggerPresenceForLeakReporting,默认为打开.通过在左括号后添加句点来禁用它:
{Set this option to require the program to be run inside the IDE debugger to report memory leaks. This option has no effect if the option "EnableMemoryLeakReporting" is not also set.} {$define RequireDebuggerPresenceForLeakReporting}
(通过@wades的请求添加此答案.)
本文共计331个文字,预计阅读时间需要2分钟。
我正在尝试使用FastMM版本4.99(根据FastMM4.pas顶部的评论)。我遵循了说明,使用了堆栈跟踪的完整调试模式,并在IDE调试器下运行我的.exe时发现了泄漏。例如,但当我尝试从命令行运行时,发现泄漏。
我正在尝试使用FastMM版本4.99(根据FastMM4.pas顶部的评论).我有 followed the instructions使用堆栈跟踪的完全调试模式,并且当我在IDE调试器下运行我的.exe时发现泄漏.例如但是当我尝试从命令提示符运行可执行文件,或者双击Windows资源管理器时,我没有报告泄漏. UnicodeString泄漏可能是假的,但我确信TIniFile泄漏是真实的.不使用调试器时,如何使FastMM报告/日志泄漏?
更新:此项目还使用madExcept 3.0n:.dpr文件确实将FastMM4作为其uses子句中的第一项.还有什么需要让这两者共存?
您尚未正确配置FastMM4Options.inc.从分发版本4.97的文件开始,它位于第405行:{Set this option to require the presence of the Delphi IDE to report memory leaks. This option has no effect if the option "EnableMemoryLeakReporting" is not also set.} {.$define RequireIDEPresenceForLeakReporting}
确保.在最后一行(在$define之前)并重建您的项目.
@wades发现还有另一个设置,紧接着我提到的设置,RequireDebuggerPresenceForLeakReporting,默认为打开.通过在左括号后添加句点来禁用它:
{Set this option to require the program to be run inside the IDE debugger to report memory leaks. This option has no effect if the option "EnableMemoryLeakReporting" is not also set.} {$define RequireDebuggerPresenceForLeakReporting}
(通过@wades的请求添加此答案.)

