check that extensions_vidmode is set before trying to use the vidmode functions
This commit is contained in:
parent
2052385333
commit
22112d2b4e
1 changed files with 4 additions and 2 deletions
|
@ -1621,7 +1621,8 @@ void client_configure(Client *self, Corner anchor, int x, int y, int w, int h,
|
|||
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 @@ void client_configure(Client *self, Corner anchor, int x, int y, int w, int h,
|
|||
#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
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue