[Pkg-lxde-maintainers] Bug#801319: Icon size problem
Lutz Fischer
fischerlutz76 at yahoo.com
Tue Oct 13 15:08:33 UTC 2015
Dear Maintainer
Looks like there is a problem with
XGetWindowProperty(...,a_NET_WM_ICON,...) returning icons with a length
and width set to -1 (or 4294967295 unsigned).
That results in trying to allocate some massive amount of memory.
following patch seem to fix the problem - basically it catches these
cases by testing for size == 1 and ignoring these icons :
-----------------------------------------------------------------
diff -Naurp lxpanel.orig/plugins/launchtaskbar.c
lxpanel/plugins/launchtaskbar.c
--- lxpanel.orig/plugins/launchtaskbar.c 2015-05-06
20:44:51.000000000 +0100
+++ lxpanel/plugins/launchtaskbar.c 2015-10-13 15:18:17.825009529 +0100
@@ -2058,7 +2058,8 @@ static GdkPixbuf * get_wm_icon(Window ta
pdata += 2;
/* Bounds check the icon. */
- if (pdata + size > pdata_end)
+ /* seems like sometimes we get w = h = -1 (4294967295)
and then size == 1 and that leads to a crash later on e.g. bug #801319 */
+ if (pdata + size > pdata_end || size == 1)
break;
/* Rare special case: the desired size is the same as
icon size. */
---------------------------------------------------------------
Lutz
More information about the Pkg-lxde-maintainers
mailing list