mirror of
https://github.com/varun-r-mallya/sysprof.git
synced 2026-02-10 15:10:53 +00:00
tests: fix leak in test
This allows the test to pass under ASAN.
This commit is contained in:
@ -97,7 +97,10 @@ test_basic (void)
|
|||||||
sp_model_filter_set_filter_func (filter, filter_func2, NULL, NULL);
|
sp_model_filter_set_filter_func (filter, filter_func2, NULL, NULL);
|
||||||
g_assert_cmpint (500, ==, g_list_model_get_n_items (G_LIST_MODEL (filter)));
|
g_assert_cmpint (500, ==, g_list_model_get_n_items (G_LIST_MODEL (filter)));
|
||||||
|
|
||||||
g_list_store_append (model, test_item_new (1001));
|
{
|
||||||
|
g_autoptr(TestItem) freeme = test_item_new (1001);
|
||||||
|
g_list_store_append (model, freeme);
|
||||||
|
}
|
||||||
|
|
||||||
for (i = 0; i < 500; i++)
|
for (i = 0; i < 500; i++)
|
||||||
g_list_store_remove (model, 0);
|
g_list_store_remove (model, 0);
|
||||||
|
|||||||
Reference in New Issue
Block a user