ccanlint: fix uninitialized variable
[ccan] / tools / ccanlint / tests / tests_pass_valgrind.c
index 30a806eb934bd5cf9799a8b74ab5e88c348d1187..4365f2a60227bc1a259ad4671d23efa72f87f0e9 100644 (file)
@@ -121,6 +121,7 @@ static void do_run_tests_vg(struct manifest *m,
                        output = grab_file(i, "valgrind.log", NULL);
                        if (!output || output[0] == '\0') {
                                err = NULL;
+                               i->leak_info = NULL;
                        } else {
                                i->leak_info = get_leaks(output, &err);
                        }
@@ -193,7 +194,7 @@ REGISTER_TEST(tests_pass_valgrind);
 
 struct ccanlint tests_pass_valgrind_noleaks = {
        .key = "tests_pass_valgrind_noleaks",
-       .name = "Module's run and api tests leak memory",
+       .name = "Module's run and api tests have no memory leaks",
        .check = do_leakcheck_vg,
        .needs = "tests_pass_valgrind"
 };