From e4bfb460eaed75d4dd665004af64dbfe2160a0de Mon Sep 17 00:00:00 2001 From: Jeremy Huddleston Date: Mon, 11 Feb 2008 15:35:53 -0800 Subject: [PATCH] render: Back to SECURITY_VERIFY_DRAWABLE instead of dixLookupDrawable... --- render/render.c | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/render/render.c b/render/render.c index daa73d3a2..d6170f674 100644 --- a/render/render.c +++ b/render/render.c @@ -620,16 +620,14 @@ ProcRenderCreatePicture (ClientPtr client) PicturePtr pPicture; DrawablePtr pDrawable; PictFormatPtr pFormat; - int len, error, rc; + int len, error; REQUEST(xRenderCreatePictureReq); REQUEST_AT_LEAST_SIZE(xRenderCreatePictureReq); LEGAL_NEW_RESOURCE(stuff->pid, client); - rc = dixLookupDrawable(&pDrawable, stuff->drawable, client, 0, - SecurityWriteAccess); - if (rc != Success) - return rc; + SECURITY_VERIFY_DRAWABLE(pDrawable, stuff->drawable, client, + SecurityWriteAccess); pFormat = (PictFormatPtr) SecurityLookupIDByType (client, stuff->format, @@ -1698,15 +1696,12 @@ ProcRenderQueryFilters (ClientPtr client) int nnames; ScreenPtr pScreen; PictureScreenPtr ps; - int i, j, len, total_bytes, rc; + int i, j, len, total_bytes; INT16 *aliases; char *names; REQUEST_SIZE_MATCH(xRenderQueryFiltersReq); - rc = dixLookupDrawable(&pDrawable, stuff->drawable, client, 0, - SecurityReadAccess); - if (rc != Success) - return rc; + SECURITY_VERIFY_DRAWABLE(pDrawable, stuff->drawable, client, SecurityReadAccess); pScreen = pDrawable->pScreen; nbytesName = 0;