Diff between a21b661c7afbc1358439e90ed153706da125de78 and 6dd75332834dac1adf4e913120378a2498e93c1d

Changed Files

File Additions Deletions Status
src/shared/tester.c +8 -0 modified

Full Patch

diff --git a/src/shared/tester.c b/src/shared/tester.c
index 30857e0..c3120fb 100644
--- a/src/shared/tester.c
+++ b/src/shared/tester.c
@@ -35,6 +35,10 @@
 
 #include <glib.h>
 
+#ifdef HAVE_VALGRIND_MEMCHECK_H
+#include <valgrind/memcheck.h>
+#endif
+
 #include "src/shared/util.h"
 #include "src/shared/tester.h"
 
@@ -339,6 +343,10 @@ static gboolean teardown_callback(gpointer user_data)
 	print_progress(test->name, COLOR_MAGENTA, "teardown");
 	test->teardown_func(test->test_data);
 
+#ifdef HAVE_VALGRIND_MEMCHECK_H
+	VALGRIND_DO_ADDED_LEAK_CHECK;
+#endif
+
 	return FALSE;
 }