From 0897839d5bffb9458abd5d2de2dcf0c1d09707ab Mon Sep 17 00:00:00 2001 From: Cosimo Cecchi Date: Sat, 29 Aug 2009 16:19:23 +0200 Subject: Fall back to the default icon if an empty icon name is set --- libempathy/empathy-account.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'libempathy') diff --git a/libempathy/empathy-account.c b/libempathy/empathy-account.c index 175bea64d..fb1b2756d 100644 --- a/libempathy/empathy-account.c +++ b/libempathy/empathy-account.c @@ -246,11 +246,12 @@ empathy_account_update (EmpathyAccount *account, icon_name = tp_asv_get_string (properties, "Icon"); - if (!EMP_STR_EMPTY (icon_name)) - { - g_free (priv->icon_name); - priv->icon_name = g_strdup (icon_name); - } + g_free (priv->icon_name); + + if (EMP_STR_EMPTY (icon_name)) + priv->icon_name = empathy_protocol_icon_name (priv->proto_name); + else + priv->icon_name = g_strdup (icon_name); } if (g_hash_table_lookup (properties, "Enabled") != NULL) -- cgit v1.2.3