CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 6 of 6
  1. #1
    Join Date
    Feb 2012
    Posts
    10

    Leak: Allocation Number increasing by one when reported

    Hi guys i have a memory leak in my program which the memory allocation number is increasing by one everytime its reported. I wanted to put a break point on it but I'm wondering if that allocation number make sense. Any idea what does it mean and how to track this? Here is the actual memory leak.

    Code:
    Detected memory leaks!
    Dumping objects ->
    {1986} normal block at 0x01CD66B0, 88 bytes long.
     Data: < Ls            > 8C 6C 45 10 00 00 00 00 CD CD CD CD 00 00 00 00 
    Object dump complete.
    Detected memory leaks!
    Dumping objects ->
    {1986} normal block at 0x01CD66B0, 88 bytes long.
     Data: < Ls             > 8C 6C 45 10 00 00 00 00 CD CD CD CD 00 00 00 00 
    Object dump complete.
    The program '[2232] SampleApp_d.exe: Native' has exited with code 0 (0x0).
    that allocation number {1986} will be come {1987} next time the leak is reported.
    Last edited by himitsujanai; February 26th, 2012 at 09:53 PM.

  2. #2
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,430

    Re: Leak: Allocation Number increasing by one when reported

    FAQ
    Victor Nijegorodov

  3. #3
    Join Date
    Nov 2000
    Location
    Voronezh, Russia
    Posts
    6,633

    Re: Leak: Allocation Number increasing by one when reported

    Last edited by Igor Vartanov; February 18th, 2012 at 04:50 AM.
    Best regards,
    Igor

  4. #4
    Join Date
    Feb 2012
    Posts
    10

    Re: Leak: Allocation Number increasing by one when reported

    Quote Originally Posted by VictorN View Post
    Thanks Victor but I already know how to manage and how to solved memory leak the point is this memory leak is a bit tricky and new to me because every time it reported the allocation number is increase by one and if i break point it its does not make any sense the one that it points to is a non suspected line of code. the others that i solved is a fixed allocation number and there's some information that u can use like the data, file and line where the leak occured

  5. #5
    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    3,654

    Re: Leak: Allocation Number increasing by one when reported

    If you know that the allocation number increase by one you can compensate for that can't you?
    Debugging is twice as hard as writing the code in the first place.
    Therefore, if you write the code as cleverly as possible, you are, by
    definition, not smart enough to debug it.
    - Brian W. Kernighan

    To enhance your chance's of getting an answer be sure to read
    http://www.codeguru.com/forum/announ...nouncementid=6
    and http://www.codeguru.com/forum/showthread.php?t=366302 before posting

    Refresh your memory on formatting tags here
    http://www.codeguru.com/forum/misc.php?do=bbcode

    Get your free MS compiler here
    https://visualstudio.microsoft.com/vs

  6. #6
    Join Date
    Apr 1999
    Posts
    27,449

    Re: Leak: Allocation Number increasing by one when reported

    Quote Originally Posted by himitsujanai View Post
    it its does not make any sense the one that it points to is a non suspected line of code.
    Please show this line of code you say is "non-suspected".

    Too many times, we get posters not showing code because they think the code isn't relevant to their problem. Then when we finally get to see the code that wasn't supposed to be relevant, it turns out that the code is the root cause of the problem.

    Regards,

    Paul McKenzie

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured