Finding Memory Leaks: Difference between revisions

m (No content changed, just a small visual makeover using the power of this wiki ;-))
 
(One intermediate revision by one other user not shown)
Line 47: Line 47:
setenv ASAN_OPTIONS "leak_check_at_exit=0:verbosity=1"
setenv ASAN_OPTIONS "leak_check_at_exit=0:verbosity=1"
</syntaxhighlight>
</syntaxhighlight>
(With recent compilers you may need to use LSAN_OPTIONS variable instead.)


This stops reporting on any leaks at the end of the program, as those will be cleaned up by the operating system anyways when the process itself is destroyed.
This stops reporting on any leaks at the end of the program, as those will be cleaned up by the operating system anyways when the process itself is destroyed.
Another useful option is "log_file=my-log-file-name".  By default, a process ID is appended to the log-file name.


== Finding Leaks ==
== Finding Leaks ==
Anonymous user