empathy r855 - trunk/libempathy
- From: xclaesse svn gnome org
- To: svn-commits-list gnome org
- Subject: empathy r855 - trunk/libempathy
- Date: Wed, 2 Apr 2008 10:42:22 +0100 (BST)
Author: xclaesse
Date: Wed Apr 2 10:42:22 2008
New Revision: 855
URL: http://svn.gnome.org/viewvc/empathy?rev=855&view=rev
Log:
ref the contact temporally when setting properties because it could destroy the object.
Modified:
trunk/libempathy/empathy-contact.c
Modified: trunk/libempathy/empathy-contact.c
==============================================================================
--- trunk/libempathy/empathy-contact.c (original)
+++ trunk/libempathy/empathy-contact.c Wed Apr 2 10:42:22 2008
@@ -381,13 +381,14 @@
g_free (priv->id);
priv->id = g_strdup (id);
+ g_object_ref (contact);
contact_set_ready_flag (contact, EMPATHY_CONTACT_READY_ID,
!G_STR_EMPTY (id));
-
g_object_notify (G_OBJECT (contact), "id");
if (G_STR_EMPTY (priv->name)) {
g_object_notify (G_OBJECT (contact), "name");
}
+ g_object_unref (contact);
}
const gchar *
@@ -422,10 +423,12 @@
g_free (priv->name);
priv->name = g_strdup (name);
+
+ g_object_ref (contact);
contact_set_ready_flag (contact, EMPATHY_CONTACT_READY_NAME,
name != NULL);
-
g_object_notify (G_OBJECT (contact), "name");
+ g_object_unref (contact);
}
EmpathyAvatar *
@@ -589,10 +592,12 @@
}
priv->handle = handle;
+
+ g_object_ref (contact);
contact_set_ready_flag (contact, EMPATHY_CONTACT_READY_HANDLE,
handle != 0);
-
g_object_notify (G_OBJECT (contact), "handle");
+ g_object_unref (contact);
}
EmpathyCapabilities
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]