From 13911ef769824a0958e1f1ce7292dfc8f23feb18 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Wed, 2 Nov 2011 09:34:29 +1030 Subject: [PATCH] ccanlint: fix uninitialized variables in tests_pass_valgrind. We weren't initializing the leak_info field when the test was marked FAIL in _info (as in tdb2). --- tools/ccanlint/tests/tests_pass_valgrind.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/ccanlint/tests/tests_pass_valgrind.c b/tools/ccanlint/tests/tests_pass_valgrind.c index 81814377..bf914856 100644 --- a/tools/ccanlint/tests/tests_pass_valgrind.c +++ b/tools/ccanlint/tests/tests_pass_valgrind.c @@ -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); -- 2.39.2