From b0e713b7758356f38ee1617945a538990330077d Mon Sep 17 00:00:00 2001 From: "Owen W. Taylor" Date: Fri, 12 Nov 2010 15:57:04 -0500 Subject: [PATCH] StIcon: use g_strcmp0() Simplify a check for an unchanged string with g_strcmp0(). https://bugzilla.gnome.org/show_bug.cgi?id=633865 --- src/st/st-icon.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/st/st-icon.c b/src/st/st-icon.c index abbab1f2d..2534fef90 100644 --- a/src/st/st-icon.c +++ b/src/st/st-icon.c @@ -509,9 +509,7 @@ st_icon_set_icon_name (StIcon *icon, priv = icon->priv; /* Check if there's no change */ - if ((!priv->icon_name && !icon_name) || - (priv->icon_name && icon_name && - g_str_equal (priv->icon_name, icon_name))) + if (g_strcmp0 (priv->icon_name, icon_name) == 0) return; g_free (priv->icon_name);