Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Memory leaks and VCRT

Memory leaks and VCRT

Scheduled Pinned Locked Moved C / C++ / MFC
performancehelpquestion
5 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • I Offline
    I Offline
    Imtiaz Murtaza
    wrote on last edited by
    #1

    Friends, I am using "Bounds Checker" for the first time. It detected cretain flaws in my code e.g buffer overruns, leaks e.t.c. I solved all these problems. Now it is not showing any problem in my code. But the problem is that, on exiting, it detects too many memory leaks in MSVCRT71.dll. Do i need to worry about these leaks ?? Also please tell me that i am using VC 6.0, and Bounds Checker is showing me that the run time dll is MSVCRT71.dll. I think MSVCRT71.dll is a part of VC 7.0 that is also installed in my machine. Is my program of VC 6.0 using correct runtime library ?? Imtiaz

    V K V H 4 Replies Last reply
    0
    • I Imtiaz Murtaza

      Friends, I am using "Bounds Checker" for the first time. It detected cretain flaws in my code e.g buffer overruns, leaks e.t.c. I solved all these problems. Now it is not showing any problem in my code. But the problem is that, on exiting, it detects too many memory leaks in MSVCRT71.dll. Do i need to worry about these leaks ?? Also please tell me that i am using VC 6.0, and Bounds Checker is showing me that the run time dll is MSVCRT71.dll. I think MSVCRT71.dll is a part of VC 7.0 that is also installed in my machine. Is my program of VC 6.0 using correct runtime library ?? Imtiaz

      V Offline
      V Offline
      virtualkirankumar
      wrote on last edited by
      #2

      Hai! i hope u may use the mfc class CMemoryState class .. u create object of that class later u call before function call which u have to check the memroy leaks after that u call another object of that class now u call this object function after function call later u compare these two objects u can find the memory leaks easily... kiran.s

      1 Reply Last reply
      0
      • I Imtiaz Murtaza

        Friends, I am using "Bounds Checker" for the first time. It detected cretain flaws in my code e.g buffer overruns, leaks e.t.c. I solved all these problems. Now it is not showing any problem in my code. But the problem is that, on exiting, it detects too many memory leaks in MSVCRT71.dll. Do i need to worry about these leaks ?? Also please tell me that i am using VC 6.0, and Bounds Checker is showing me that the run time dll is MSVCRT71.dll. I think MSVCRT71.dll is a part of VC 7.0 that is also installed in my machine. Is my program of VC 6.0 using correct runtime library ?? Imtiaz

        K Offline
        K Offline
        Kiran Kumar Singani
        wrote on last edited by
        #3

        Hai! i hope u may use the mfc class CMemoryState class .. u create object of that class later u call before function call which u have to check the memroy leaks after that u call another object of that class now u call this object function after function call later u compare these two objects u can find the memory leaks easily... kiran.s

        1 Reply Last reply
        0
        • I Imtiaz Murtaza

          Friends, I am using "Bounds Checker" for the first time. It detected cretain flaws in my code e.g buffer overruns, leaks e.t.c. I solved all these problems. Now it is not showing any problem in my code. But the problem is that, on exiting, it detects too many memory leaks in MSVCRT71.dll. Do i need to worry about these leaks ?? Also please tell me that i am using VC 6.0, and Bounds Checker is showing me that the run time dll is MSVCRT71.dll. I think MSVCRT71.dll is a part of VC 7.0 that is also installed in my machine. Is my program of VC 6.0 using correct runtime library ?? Imtiaz

          V Offline
          V Offline
          vishalmore
          wrote on last edited by
          #4

          But the problem is that, on exiting, it detects too many memory leaks in MSVCRT71.dll. Do i need to worry about these leaks ?? Don't worry about it ! ;) Also please tell me that i am using VC 6.0, and Bounds Checker is showing me that the run time dll is MSVCRT71.dll. I think MSVCRT71.dll is a part of VC 7.0 that is also installed in my machine. Is my program of VC 6.0 using correct runtime library ?? Might be some cross link, don't worry about it ! :) If your application is some dll, then you should use dependency viewer of VS6, just to track dependency of ur application on several dll's. Check whether "MSVCRT71.dll" is there ? Regards, Vishal

          1 Reply Last reply
          0
          • I Imtiaz Murtaza

            Friends, I am using "Bounds Checker" for the first time. It detected cretain flaws in my code e.g buffer overruns, leaks e.t.c. I solved all these problems. Now it is not showing any problem in my code. But the problem is that, on exiting, it detects too many memory leaks in MSVCRT71.dll. Do i need to worry about these leaks ?? Also please tell me that i am using VC 6.0, and Bounds Checker is showing me that the run time dll is MSVCRT71.dll. I think MSVCRT71.dll is a part of VC 7.0 that is also installed in my machine. Is my program of VC 6.0 using correct runtime library ?? Imtiaz

            H Offline
            H Offline
            Henry miller
            wrote on last edited by
            #5

            That depends. Not all "leaks" are detected correctly, it has happened where a bound checker has found a leak that wasn't a problem. (I don't know about yours in particular, though. I'd start with the assumption that you should worry) There are two possibilities. First, MSVCRT71.dll might be programed incorrectly, and therefore there is nothing you can do other than upgrade to a newer version if one exists. Odds are strongly against this case, but it has happened, so if you get nowhere you might want to check into it. More likley is that you are using the library incorrectly. Read the documentaiton for all the functions you use. Look for the little line that says something like "allocates a foo resource which the caller must free when done by a call to freefoo()". Your bounds checker might give you a clue where to look first, but sometimes you just have to read the documentation for every function, and then check each time you use it.

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups