Browse Source

ccanlint: Fix leak in do_reduce_features()

options_avail and options_used get freed, but options does not.

Found by Coverity scan.

Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
David Gibson 8 years ago
parent
commit
6251b771b3
1 changed files with 1 additions and 0 deletions
  1. 1 0
      tools/ccanlint/tests/reduce_features.c

+ 1 - 0
tools/ccanlint/tests/reduce_features.c

@@ -181,6 +181,7 @@ static void do_reduce_features(struct manifest *m,
 		err(1, "Creating reduced-features/config.h");
 	if (!write_all(fd, hdr, strlen(hdr)))
 		err(1, "Writing reduced-features/config.h");
+	htable_option_free(options);
 	close(fd);
 	features_were_reduced = true;
 }