Browse Source

ccanlint: don't crash when given --target=hash_if and there's no _info file.

Rusty Russell 15 years ago
parent
commit
b55c668069
1 changed files with 2 additions and 1 deletions
  1. 2 1
      tools/ccanlint/ccanlint.c

+ 2 - 1
tools/ccanlint/ccanlint.c

@@ -665,7 +665,8 @@ int main(int argc, char *argv[])
 	}
 
 	/* --target overrides known FAIL from _info */
-	add_info_options(m->info_file, !target);
+	if (m->info_file)
+		add_info_options(m->info_file, !target);
 
 	while ((i = get_next_test(&normal_tests)) != NULL)
 		run_test(i, summary, &score, &total_score, m);