如何检测本机C ++应用程序中的内存泄漏? [英] How to detect memory leaks in a native C++ application?

查看:68
本文介绍了如何检测本机C ++应用程序中的内存泄漏?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用Analyze-> Performance Profiler并检查内存使用情况以查看是否可以捕获内存泄漏但是当我按下Start时它会运行应用程序而不会在任何断点处停止并显示没有泄漏 - 而我知道有一个内存泄漏,因为
我在应用程序的main()中种了一个。那么,我做错了什么?

I am trying to use Analyze->Performance Profiler and check Memory Usage to see if I can catch memory leaks but when I press Start it runs the application without stopping in any breakpoints and shows no leakage -- while I know there is a memory leak because I planted one in the main() of the application. So, what am I doing wrong?

Juan Dent

Juan Dent

推荐答案

你读过这个吗?



使用CRT库查找内存泄漏

https://docs.microsoft.com/en-us/visualstudio/debugger/finding-memory-leaks-using-the- crt-library?view = vs-2015



- Wayne

Have you read this?

Finding Memory Leaks Using the CRT Library
https://docs.microsoft.com/en-us/visualstudio/debugger/finding-memory-leaks-using-the-crt-library?view=vs-2015

- Wayne


这篇关于如何检测本机C ++应用程序中的内存泄漏?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆