CppBuzz.com
  
Home C C++ Java Python Perl PHP SQL Javascript Linux Forum

You are here : Home » C++ » How to find Memory leak in C++

How to find Memory leak in C++ using Valgrind

Valgrind is the best tools ever to detect memory leak in C/C++ on Linux. Its free and can be downloaded easiely. It basically results two types of memory leak first one is Direct memory leak while other one is Indirect memory leak.

Direct Memory Leak - In this programmer miss to deleted allocated memory.
Indiret Memory Leak - In this, memory is leak by inbuild library functions, which we can't fix.

Example of output produced by Valgrind:

memory leak in C++

Other links

MCQ on C Programming MCQ on C++ Programming 138+C++ F2F Interview Questions Basic Computer Questions Solved C programs Solved C++ programs