mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-01-08 15:20:15 +01:00
avoid a potential endless loop.
Previously it is possible that creating rotation data, then cleaning
up and creating again so that pScreen->BlockHandler and
xf86_config->BlockHandler all point to xf86RotateBlockHandler.
See bug #19343.
(cherry picked from commit 5f3188228e)
This commit is contained in:
parent
840b4da5f2
commit
ef796a95dd
1 changed files with 6 additions and 2 deletions
|
|
@ -291,6 +291,8 @@ xf86RotateBlockHandler(int screenNum, pointer blockData,
|
|||
/* Re-wrap if rotation is still happening */
|
||||
xf86_config->BlockHandler = pScreen->BlockHandler;
|
||||
pScreen->BlockHandler = xf86RotateBlockHandler;
|
||||
} else {
|
||||
xf86_config->BlockHandler = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -477,8 +479,10 @@ xf86CrtcRotate (xf86CrtcPtr crtc)
|
|||
goto bail2;
|
||||
|
||||
/* Wrap block handler */
|
||||
xf86_config->BlockHandler = pScreen->BlockHandler;
|
||||
pScreen->BlockHandler = xf86RotateBlockHandler;
|
||||
if (!xf86_config->BlockHandler) {
|
||||
xf86_config->BlockHandler = pScreen->BlockHandler;
|
||||
pScreen->BlockHandler = xf86RotateBlockHandler;
|
||||
}
|
||||
}
|
||||
#ifdef RANDR_12_INTERFACE
|
||||
if (transform)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue