How is valgrind used for memory leaks?

How is valgrind used for memory leaks?
Answer
Valgrind includes an option to check for memory leaks. With no option given, it will list a heap summary where it will say if there is any memory that has been allocated but not freed. If you use the option –leak-check=full it will give more information.
 

Tìm kiếm

Back
Top