From 98676613fd5c6fcc4f49079fe2d73b96f465b09f Mon Sep 17 00:00:00 2001 From: Michael Vetter Date: Sun, 6 Oct 2019 18:45:53 +0200 Subject: [PATCH] Free strings in test_cmd_alias Regards https://github.com/profanity-im/profanity/issues/1019 --- tests/unittests/test_cmd_alias.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/unittests/test_cmd_alias.c b/tests/unittests/test_cmd_alias.c index d1cdaf01..b7f27d3d 100644 --- a/tests/unittests/test_cmd_alias.c +++ b/tests/unittests/test_cmd_alias.c @@ -70,6 +70,8 @@ void cmd_alias_add_adds_alias(void **state) char *returned_val = prefs_get_alias("hc"); assert_string_equal("/help commands", returned_val); + + free(returned_val); } void cmd_alias_add_shows_message_when_exists(void **state) @@ -99,6 +101,8 @@ void cmd_alias_remove_removes_alias(void **state) char *returned_val = prefs_get_alias("hn"); assert_null(returned_val); + + free(returned_val); } void cmd_alias_remove_shows_message_when_no_alias(void **state)