summaryrefslogtreecommitdiff
path: root/libcaja-private
diff options
context:
space:
mode:
authorWolfgang Ulbrich <[email protected]>2016-01-07 23:42:36 +0100
committerWolfgang Ulbrich <[email protected]>2016-01-13 15:05:41 +0100
commit34031cbce020b242d523258e06565c6a00c54e5d (patch)
treeba6361fc14e34dd293243e4b4c8f7f8b966e3e63 /libcaja-private
parent7eea4d477154160e3dd52b76346218b0ca22f8ed (diff)
downloadcaja-34031cbce020b242d523258e06565c6a00c54e5d.tar.bz2
caja-34031cbce020b242d523258e06565c6a00c54e5d.tar.xz
GTK3 icon-info: plug a leak
taken from: https://git.gnome.org/browse/nautilus/commit/?h=gnome-3-0&id=705d814
Diffstat (limited to 'libcaja-private')
-rw-r--r--libcaja-private/caja-icon-info.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/libcaja-private/caja-icon-info.c b/libcaja-private/caja-icon-info.c
index 3a63bb44..d5bd542e 100644
--- a/libcaja-private/caja-icon-info.c
+++ b/libcaja-private/caja-icon-info.c
@@ -472,7 +472,13 @@ caja_icon_info_lookup (GIcon *icon,
pixbuf = NULL;
}
- return caja_icon_info_new_for_pixbuf (pixbuf);
+ icon_info = caja_icon_info_new_for_pixbuf (pixbuf);
+
+ if (pixbuf != NULL) {
+ g_object_unref (pixbuf);
+ }
+
+ return icon_info;
}
}