mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2025-12-25 16:30:05 +01:00
DGA: Fix ProcXF86DGASetViewPort for missing support in driver.
Fixes a segfault when trying to activate a DGA mode without checking
whether DGA modesetting is at all possible.
(cherry picked from commit 1feb69eb63)
This commit is contained in:
parent
4e6cbd3238
commit
8337c9aa3d
1 changed files with 5 additions and 2 deletions
|
|
@ -93,7 +93,7 @@ ProcXF86DGADirectVideo(ClientPtr client)
|
|||
|
||||
REQUEST_SIZE_MATCH(xXF86DGADirectVideoReq);
|
||||
|
||||
if (!DGAAvailable(stuff->screen))
|
||||
if (!DGAAvailable(stuff->screen))
|
||||
return DGAErrorBase + XF86DGANoDirectVideoMode;
|
||||
|
||||
if (stuff->enable & XF86DGADirectGraphics) {
|
||||
|
|
@ -128,7 +128,7 @@ ProcXF86DGAGetViewPortSize(ClientPtr client)
|
|||
rep.length = 0;
|
||||
rep.sequenceNumber = client->sequence;
|
||||
|
||||
if (!DGAAvailable(stuff->screen))
|
||||
if (!DGAAvailable(stuff->screen))
|
||||
return (DGAErrorBase + XF86DGANoDirectVideoMode);
|
||||
|
||||
if(!(num = DGAGetOldDGAMode(stuff->screen)))
|
||||
|
|
@ -153,6 +153,9 @@ ProcXF86DGASetViewPort(ClientPtr client)
|
|||
|
||||
REQUEST_SIZE_MATCH(xXF86DGASetViewPortReq);
|
||||
|
||||
if (!DGAAvailable(stuff->screen))
|
||||
return (DGAErrorBase + XF86DGANoDirectVideoMode);
|
||||
|
||||
if (!DGAActive(stuff->screen))
|
||||
{
|
||||
int num;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue