ccanlint: fix uninitialized variables in tests_pass_valgrind.
[ccan] / tools / ccanlint / tests / tests_pass_valgrind.c
index 818143777e2571e934bc59e98d215a1b3bf7bfcf..bf914856845f2a7a42e9cec97d210c9b7c3ef06a 100644 (file)
@@ -165,8 +165,10 @@ static void do_run_tests_vg(struct manifest *m,
                        options = concat(score,
                                         per_file_options(&tests_pass_valgrind,
                                                          i));
-                       if (streq(options, "FAIL"))
+                       if (streq(options, "FAIL")) {
+                               i->leak_info = NULL;
                                continue;
+                       }
 
                        if (keep)
                                talloc_set_destructor(i->valgrind_log, NULL);