This commit is contained in:
Dana Jansens 2007-06-07 16:25:23 +00:00
parent 364a8704fb
commit 4b84ef021f

View file

@ -2047,18 +2047,19 @@ void client_update_icons(ObClient *self)
if ((hints = XGetWMHints(ob_display, self->window))) { if ((hints = XGetWMHints(ob_display, self->window))) {
if (hints->flags & IconPixmapHint) { if (hints->flags & IconPixmapHint) {
self->nicons++; self->nicons = 1;
self->icons = g_new(ObClientIcon, self->nicons); self->icons = g_new(ObClientIcon, self->nicons);
xerror_set_ignore(TRUE); xerror_set_ignore(TRUE);
if (!RrPixmapToRGBA(ob_rr_inst, if (!RrPixmapToRGBA(ob_rr_inst,
hints->icon_pixmap, hints->icon_pixmap,
(hints->flags & IconMaskHint ? (hints->flags & IconMaskHint ?
hints->icon_mask : None), hints->icon_mask : None),
&self->icons[self->nicons-1].width, &self->icons[0].width,
&self->icons[self->nicons-1].height, &self->icons[0].height,
&self->icons[self->nicons-1].data)){ &self->icons[0].data))
/*g_free(&self->icons[self->nicons-1]);*/ {
self->nicons--; g_free(self->icons);
self->nicons = 0;
} }
xerror_set_ignore(FALSE); xerror_set_ignore(FALSE);
} }