all repos — openbox @ 22112d2b4edced2de346d28cf6ee791cc805fe56

openbox fork - make it a bit more like ryudo

check that extensions_vidmode is set before trying to use the vidmode functions
Dana Jansens danakj@orodu.net
commit

22112d2b4edced2de346d28cf6ee791cc805fe56

parent

2052385333dd5fc8285a1bbc20700cdb2f45bd3b

1 files changed, 4 insertions(+), 2 deletions(-)

jump to
M openbox/client.copenbox/client.c

@@ -1621,7 +1621,8 @@ #ifdef VIDMODE

int dot; XF86VidModeModeLine mode; - if (XF86VidModeGetModeLine(ob_display, ob_screen, &dot, &mode)) { + if (extensions_vidmode && + XF86VidModeGetModeLine(ob_display, ob_screen, &dot, &mode)) { w = mode.hdisplay; h = mode.vdisplay; if (mode.privsize) XFree(mode.private);

@@ -1632,7 +1633,8 @@ h = screen_physical_size.height;

#endif #ifdef VIDMODE } - if (!XF86VidModeGetViewPort(ob_display, ob_screen, &x, &y)) { + if (!(extensions_vidmode && + XF86VidModeGetViewPort(ob_display, ob_screen, &x, &y))) { x = y = 0; #endif }