[recipes] Fix another small memory leak
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [recipes] Fix another small memory leak
- Date: Sat, 31 Dec 2016 04:47:18 +0000 (UTC)
commit d06d4426c32e2b1074b632de58a3dc91b17ee9d5
Author: Matthias Clasen <mclasen redhat com>
Date: Fri Dec 30 21:27:04 2016 -0500
Fix another small memory leak
src/gr-recipe-store.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/gr-recipe-store.c b/src/gr-recipe-store.c
index 721aa85..41e8377 100644
--- a/src/gr-recipe-store.c
+++ b/src/gr-recipe-store.c
@@ -1237,7 +1237,6 @@ gr_recipe_store_get_all_ingredients (GrRecipeStore *self,
while (g_hash_table_iter_next (&iter, NULL, (gpointer *)&recipe)) {
const char *ingredients;
GrIngredientsList *list = NULL;
- g_autofree char **ret = NULL;
g_autofree char **segments = NULL;
ingredients = gr_recipe_get_ingredients (recipe);
@@ -1248,6 +1247,7 @@ gr_recipe_store_get_all_ingredients (GrRecipeStore *self,
list = gr_ingredients_list_new (ingredients);
segments = gr_ingredients_list_get_segments (list);
for (j = 0; segments[j]; j++) {
+ g_autofree char **ret = NULL;
ret = gr_ingredients_list_get_ingredients (list, segments[j]);
for (i = 0; ret[i]; i++)
g_hash_table_add (ingreds, ret[i]);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]