summaryrefslogtreecommitdiff
path: root/tests/libtracker-common
diff options
context:
space:
mode:
authorAndrea Azzarone <andrea.azzarone@canonical.com>2019-01-18 17:17:46 +0000
committerAndrea Azzarone <andrea.azzarone@canonical.com>2019-01-24 16:47:16 +0000
commitb4ed2851fea73aeb29a68b372d496953262caa72 (patch)
treebaa61438e483a463fe245855fed257d177cce97b /tests/libtracker-common
parent33fd803213846e6584acd7f186764c3e21a63d32 (diff)
downloadtracker-b4ed2851fea73aeb29a68b372d496953262caa72.tar.gz
tests/libtracker-common: Fix memory leaks
Make sure to call g_free on result in tracker-type-utils-test.c
Diffstat (limited to 'tests/libtracker-common')
-rw-r--r--tests/libtracker-common/tracker-type-utils-test.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/libtracker-common/tracker-type-utils-test.c b/tests/libtracker-common/tracker-type-utils-test.c
index 808c78094..5fce83406 100644
--- a/tests/libtracker-common/tracker-type-utils-test.c
+++ b/tests/libtracker-common/tracker-type-utils-test.c
@@ -56,6 +56,7 @@ test_string_in_string_list (void)
g_assert_cmpint (tracker_string_in_string_list ("is", pieces), ==, 1);
g_assert_cmpint (tracker_string_in_string_list ("Audio:Title", pieces), ==, 12);
+ g_strfreev (pieces);
g_assert_cmpint (tracker_string_in_string_list ("terms", NULL), ==, -1);
}
@@ -143,6 +144,7 @@ test_string_to_string_list (void)
result = tracker_string_to_string_list (input);
g_assert_cmpint (g_strv_length (result), ==, 1);
g_assert_cmpstr (result [0], ==, "first line");
+ g_strfreev (result);
}
static void