|
-
July 8th, 2010, 09:30 PM
#1
How to identify memory leaks?
Hello,
I want to check whether memory leaks exists in my prog. I use VS 2008 standard edition. I see that there is an in built debugger which makes life simpler to debug.
I came across this link
http://msdn.microsoft.com/en-us/libr...=VS.80%29.aspx
I followed the steps, but i am not able to get the line number and filename where memory is leaking. Only thing is it is dumping the memory leaks.
Now my question is whatever it displays, the block of memory, is that full memory leak??
I mean there are values like,
00 00 00 02 14 B2 CD 00.......
or
.... 00 14 00 CD CD CD CD
or full of zeros...
How do i identify which one is having memory leak? Whats the rule to identify based in this data which block is leaking.?
Suggestions and comments required urgently.
Thanks
-
July 9th, 2010, 03:24 AM
#2
Re: How to identify memory leaks?
Please, show the exact "memory leaks" message, not your own skipped version of it!
Victor Nijegorodov
-
July 9th, 2010, 03:16 PM
#3
Re: How to identify memory leaks?
You can use _CrtDbgBreak in the watch window, to break at the block allocation that generated the leak. But you need to get a reproduceable scenario, with the same allocation numbers generating leaks for each run.
-
July 9th, 2010, 04:25 PM
#4
Re: How to identify memory leaks?
-
July 12th, 2010, 02:37 AM
#5
Re: How to identify memory leaks?
Here is an FAQ about how to find the source of memory leaks: http://www.codeguru.com/forum/showthread.php?t=499952.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|