[telepathy-mission-control/master] _mcd_channel_details_free: use g_boxed_free instead of playing with GValues

Simon McVittie simon.mcvittie at collabora.co.uk
Mon Nov 2 07:18:10 PST 2009


---
 src/mcd-channel.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)

diff --git a/src/mcd-channel.c b/src/mcd-channel.c
index 4ee122b..ea1ec65 100644
--- a/src/mcd-channel.c
+++ b/src/mcd-channel.c
@@ -1113,12 +1113,7 @@ _mcd_channel_details_build_from_list (const GList *channels)
 void
 _mcd_channel_details_free (GPtrArray *channels)
 {
-    GValue value = { 0, };
-
-    /* to free the array, put it into a GValue */
-    g_value_init (&value, TP_ARRAY_TYPE_CHANNEL_DETAILS_LIST);
-    g_value_take_boxed (&value, channels);
-    g_value_unset (&value);
+    g_boxed_free (TP_ARRAY_TYPE_CHANNEL_DETAILS_LIST, channels);
 }
 
 /*
-- 
1.5.6.5




More information about the telepathy-commits mailing list