xselinux: Fix GetDrawableContext
M_DRAWABLE_PIXMAP is the lookup mask to dixLookupDrawable, and _not_ the type value in the drawable itself. Signed-off-by: Adam Jackson <ajax@redhat.com> Reviewed-by: Eamon Walsh <ewalsh@tycho.nsa.gov> Signed-off-by: Keith Packard <keithp@keithp.com>
This commit is contained in:
parent
be3be7580b
commit
ac0a00a840
|
@ -231,13 +231,11 @@ ProcSELinuxGetDrawableContext(ClientPtr client)
|
||||||
REQUEST(SELinuxGetContextReq);
|
REQUEST(SELinuxGetContextReq);
|
||||||
REQUEST_SIZE_MATCH(SELinuxGetContextReq);
|
REQUEST_SIZE_MATCH(SELinuxGetContextReq);
|
||||||
|
|
||||||
rc = dixLookupDrawable(&pDraw, stuff->id, client,
|
rc = dixLookupDrawable(&pDraw, stuff->id, client, 0, DixGetAttrAccess);
|
||||||
M_WINDOW | M_DRAWABLE_PIXMAP,
|
|
||||||
DixGetAttrAccess);
|
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
|
|
||||||
if (pDraw->type == M_DRAWABLE_PIXMAP)
|
if (pDraw->type == DRAWABLE_PIXMAP)
|
||||||
privatePtr = &((PixmapPtr)pDraw)->devPrivates;
|
privatePtr = &((PixmapPtr)pDraw)->devPrivates;
|
||||||
else
|
else
|
||||||
privatePtr = &((WindowPtr)pDraw)->devPrivates;
|
privatePtr = &((WindowPtr)pDraw)->devPrivates;
|
||||||
|
|
Loading…
Reference in New Issue