summaryrefslogtreecommitdiff
path: root/libslab
diff options
context:
space:
mode:
Diffstat (limited to 'libslab')
-rw-r--r--libslab/mate-utils.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libslab/mate-utils.c b/libslab/mate-utils.c
index 90dd9320..8dafe11a 100644
--- a/libslab/mate-utils.c
+++ b/libslab/mate-utils.c
@@ -56,7 +56,8 @@ load_image_by_id (GtkImage * image, GtkIconSize size, const gchar * image_id)
icon_theme = gtk_icon_theme_get_default ();
pixbuf = gtk_icon_theme_load_icon (icon_theme, id, width, 0, NULL);
- if (pixbuf != NULL) {
+ icon_exists = (pixbuf != NULL);
+ if (icon_exists) {
gtk_image_set_from_pixbuf (image, pixbuf);
g_object_unref (pixbuf);
}