[empathy/gnome-3-0] main_window_flash_foreach: fix FolksIndividual leak



commit 53d0828ec31130434fa70f88af45e313a5bd104d
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date:   Tue Jun 7 15:13:54 2011 +0200

    main_window_flash_foreach: fix FolksIndividual leak

 src/empathy-main-window.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)
---
diff --git a/src/empathy-main-window.c b/src/empathy-main-window.c
index 094be41..db27766 100644
--- a/src/empathy-main-window.c
+++ b/src/empathy-main-window.c
@@ -207,10 +207,8 @@ main_window_flash_foreach (GtkTreeModel *model,
 		return FALSE;
 
 	contact = empathy_contact_dup_from_folks_individual (individual);
-	if (contact != data->event->contact) {
-		tp_clear_object (&contact);
-		return FALSE;
-	}
+	if (contact != data->event->contact)
+		goto out;
 
 	if (data->on) {
 		icon_name = data->event->icon_name;
@@ -239,6 +237,7 @@ main_window_flash_foreach (GtkTreeModel *model,
 		gtk_tree_path_free (parent_path);
 	}
 
+out:
 	g_object_unref (individual);
 	tp_clear_object (&contact);
 	tp_clear_object (&pixbuf);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]