]> git.0d.be Git - empathy.git/commitdiff
Cope with status being NULL
authorSjoerd Simons <sjoerd.simons@collabora.co.uk>
Sat, 30 May 2009 21:48:26 +0000 (22:48 +0100)
committerSjoerd Simons <sjoerd.simons@collabora.co.uk>
Sat, 30 May 2009 21:48:26 +0000 (22:48 +0100)
libempathy-gtk/empathy-presence-chooser.c

index 4fd524e64c0d9299fe41f1b9d0a33c91eec5028e..9f8c568c52cffa5fd6445d0cfdf4a113dbbb6717 100644 (file)
@@ -432,7 +432,7 @@ ui_set_custom_state (EmpathyPresenceChooser *self,
        gtk_entry_set_icon_from_icon_name (GTK_ENTRY (entry),
                                           GTK_ENTRY_ICON_PRIMARY,
                                           icon_name);
-       gtk_entry_set_text (GTK_ENTRY (entry), status);
+       gtk_entry_set_text (GTK_ENTRY (entry), status == NULL ? "" : status);
        presence_chooser_set_favorite_icon (self);
 
        priv->block_changed--;
@@ -873,7 +873,7 @@ presence_chooser_presence_changed_cb (EmpathyPresenceChooser *chooser)
                                COL_STATUS_TEXT, &m_status,
                                -1);
 
-               match = !strcmp (status, m_status);
+               match = !tp_strdiff (status, m_status);
 
                g_free (m_status);