updated on Wed Jan 25 08:34:36 UTC 2012
[aur-mirror.git] / firestarter-gtkstatusicon / 18_fix_memleak.patch
blobcf5b477ca263e0a6ea93a3656bc873665f914e34
1 diff -Naur firestarter-1.0.3.orig/src/preferences.c firestarter-1.0.3/src/preferences.c
2 --- firestarter-1.0.3.orig/src/preferences.c 2005-01-29 12:32:08.000000000 +0000
3 +++ firestarter-1.0.3/src/preferences.c 2008-01-22 18:15:14.000000000 +0000
4 @@ -273,7 +273,7 @@
5 1, _("Advanced Options"),
6 -1);
7 gtk_tree_iter_free (top_section);
8 - gtk_tree_iter_free (iter);
9 + g_free (iter);
11 return GTK_TREE_MODEL (store);
13 diff -Naur firestarter-1.0.3.orig/src/statusview.c firestarter-1.0.3/src/statusview.c
14 --- firestarter-1.0.3.orig/src/statusview.c 2005-01-29 12:32:08.000000000 +0000
15 +++ firestarter-1.0.3/src/statusview.c 2008-01-22 18:15:32.000000000 +0000
16 @@ -773,7 +773,7 @@
18 Connection_entry *entry = (Connection_entry *)data;
20 - gtk_tree_iter_free (entry->ref);
21 + g_free (entry->ref);
22 g_free (data);
25 diff -Naur firestarter-1 (copy).0.3/src/policyview.c firestarter-1.0.3/src/policyview.c
26 --- firestarter-1.0.3.orig/src/policyview.c 2005-01-29 12:32:08.000000000 +0000
27 +++ firestarter-1.0.3/src/policyview.c 2008-04-09 23:35:32.000000000 +0100
28 @@ -146,7 +146,7 @@
30 g_strfreev (tokens);
31 if (view != NULL)
32 - gtk_tree_iter_free (iter);
33 + g_free (iter);
34 return TRUE;
37 @@ -218,7 +218,9 @@
38 gtk_entry_set_text (GTK_ENTRY (element), "");
41 - g_object_steal_data (G_OBJECT (dialog), "editing");
42 + GtkTreeIter *iter = g_object_steal_data (G_OBJECT (dialog), "editing");
43 + if (iter)
44 + g_free(iter);
47 static gboolean
48 @@ -428,7 +430,7 @@
49 gtk_list_store_remove (GTK_LIST_STORE (model), iter); /* Remove from the view */
50 remove_line_from_file (rule_file, (int)position);
52 - gtk_tree_iter_free (iter);
53 + g_free (iter);
56 append_to_file (rule_file, data, TRUE);