[farsight2/master] Fix small leaks in nice transmitter and tests

Olivier Crête olivier.crete at collabora.co.uk
Tue Dec 23 15:26:48 PST 2008


---
 tests/check/transmitter/nice.c                 |    2 +-
 transmitters/nice/fs-nice-stream-transmitter.c |    3 +++
 2 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/tests/check/transmitter/nice.c b/tests/check/transmitter/nice.c
index 0d5cdad..1a5a2a7 100644
--- a/tests/check/transmitter/nice.c
+++ b/tests/check/transmitter/nice.c
@@ -525,7 +525,7 @@ GST_START_TEST (test_nicetransmitter_preferred_candidates)
 
   param.name = "preferred-local-candidates";
   g_value_init (&param.value, FS_TYPE_CANDIDATE_LIST);
-  g_value_set_boxed (&param.value, list);
+  g_value_take_boxed (&param.value, list);
 
   run_nice_transmitter_test (1, &param, FLAG_IS_LOCAL);
 
diff --git a/transmitters/nice/fs-nice-stream-transmitter.c b/transmitters/nice/fs-nice-stream-transmitter.c
index b3e3501..31cac0a 100644
--- a/transmitters/nice/fs-nice-stream-transmitter.c
+++ b/transmitters/nice/fs-nice-stream-transmitter.c
@@ -380,6 +380,9 @@ fs_nice_stream_transmitter_finalize (GObject *object)
 
   fs_candidate_list_destroy (self->priv->preferred_local_candidates);
 
+  if (self->priv->relay_info)
+    g_value_array_free (self->priv->relay_info);
+
   g_free (self->priv->stun_ip);
 
   g_mutex_free (self->priv->mutex);
-- 
1.5.6.5




More information about the farsight-commits mailing list