aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk/empathy-individual-view.c
diff options
context:
space:
mode:
authorPhilip Withnall <philip.withnall@collabora.co.uk>2010-07-01 21:26:04 +0800
committerTravis Reitter <treitter@gmail.com>2010-07-21 07:12:36 +0800
commit2999dda22d4d80df40420334273fcbb7aadac091 (patch)
tree549463c23113f3228b6e789ebfba4920d3427a1b /libempathy-gtk/empathy-individual-view.c
parent336c38712dde2938b1ead01f05e1cd01f96c888d (diff)
downloadgsoc2013-empathy-2999dda22d4d80df40420334273fcbb7aadac091.tar.gz
gsoc2013-empathy-2999dda22d4d80df40420334273fcbb7aadac091.tar.zst
gsoc2013-empathy-2999dda22d4d80df40420334273fcbb7aadac091.zip
Fix some referencing bugs with the IndividualStore and IndividualView
Diffstat (limited to 'libempathy-gtk/empathy-individual-view.c')
-rw-r--r--libempathy-gtk/empathy-individual-view.c19
1 files changed, 11 insertions, 8 deletions
diff --git a/libempathy-gtk/empathy-individual-view.c b/libempathy-gtk/empathy-individual-view.c
index 5c8e96b80..e75f3629e 100644
--- a/libempathy-gtk/empathy-individual-view.c
+++ b/libempathy-gtk/empathy-individual-view.c
@@ -295,12 +295,12 @@ individual_view_query_tooltip_cb (EmpathyIndividualView *view,
{
goto OUT;
}
- else
- {
- contact = empathy_contact_from_folks_individual (individual);
- if (contact == NULL)
- goto OUT;
- }
+
+ contact = empathy_contact_from_folks_individual (individual);
+ g_object_unref (individual);
+
+ if (contact == NULL)
+ goto OUT;
if (!priv->tooltip_widget)
{
@@ -322,7 +322,6 @@ individual_view_query_tooltip_cb (EmpathyIndividualView *view,
ret = TRUE;
g_object_unref (contact);
- g_object_unref (individual);
OUT:
running--;
@@ -648,7 +647,6 @@ individual_view_drag_motion (GtkWidget *widget,
gdk_drag_status (context, GDK_ACTION_COPY, time_);
gtk_tree_view_set_drag_dest_row (GTK_TREE_VIEW (widget),
path, GTK_TREE_VIEW_DROP_INTO_OR_BEFORE);
- g_object_unref (individual);
}
else
{
@@ -656,6 +654,9 @@ individual_view_drag_motion (GtkWidget *widget,
gtk_tree_view_set_drag_dest_row (GTK_TREE_VIEW (widget), NULL, 0);
retval = FALSE;
}
+
+ if (individual != NULL)
+ g_object_unref (individual);
}
if (!is_different && !cleanup)
@@ -768,6 +769,8 @@ individual_view_drag_data_get (GtkWidget *widget,
(guchar *) individual_id, strlen (individual_id) + 1);
break;
}
+
+ g_object_unref (individual);
}
static void