1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-19 12:28:22 +01:00

Fix NULL pointer dereference

Some weird applications like Safari for Windows running on CXOffice
or some applications running on Wine were causing wmaker to crash.
So let's not rely on a window's `frame' property to be not NULL in
src/wmspec.c.

Original-post: http://lists.windowmaker.info/dev/msg00161.html
See-also: http://lists.windowmaker.info/dev/msg00222.html
This commit is contained in:
Martin Dietze
2008-11-26 15:56:33 +01:00
committed by Carlos R. Mafra
parent d6c134f420
commit a9aeefbe70

View File

@@ -1215,11 +1215,13 @@ static void updateWindowType(WWindow * wwin)
XFree(data); XFree(data);
} }
ChangeStackingLevel(wwin->frame->core, layer); if (wwin->frame != NULL) {
wwin->frame->flags.need_texture_change = 1; ChangeStackingLevel(wwin->frame->core, layer);
wWindowConfigureBorders(wwin); wwin->frame->flags.need_texture_change = 1;
wFrameWindowPaint(wwin->frame); wWindowConfigureBorders(wwin);
wNETWMUpdateActions(wwin, False); wFrameWindowPaint(wwin->frame);
wNETWMUpdateActions(wwin, False);
}
} }
Bool wNETWMCheckClientHints(WWindow * wwin, int *layer, int *workspace) Bool wNETWMCheckClientHints(WWindow * wwin, int *layer, int *workspace)