summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEamon Walsh <ewalsh@tycho.nsa.gov>2006-12-14 18:27:09 -0500
committerEamon Walsh <ewalsh@moss-huskies.epoch.ncsc.mil>2006-12-14 18:27:09 -0500
commit5e334f06a1ef89891f9df2a371e4662340bec26b (patch)
treeef09e836fe96078e91fd16bff00322e6c58bc935
parent51b69ff499c05f59cb1e577c4e8abf6f7f283b3e (diff)
Remove instances of macros VERIFY_GEOMETRABLE and VERIFY_GC.
-rw-r--r--Xext/panoramiXprocs.c6
-rw-r--r--Xext/shm.c18
-rw-r--r--Xext/xf86bigfont.c1
-rw-r--r--dix/dispatch.c1
4 files changed, 18 insertions, 8 deletions
diff --git a/Xext/panoramiXprocs.c b/Xext/panoramiXprocs.c
index 2bf94a998..a193c4188 100644
--- a/Xext/panoramiXprocs.c
+++ b/Xext/panoramiXprocs.c
@@ -531,10 +531,14 @@ int PanoramiXGetGeometry(ClientPtr client)
{
xGetGeometryReply rep;
DrawablePtr pDraw;
+ int rc;
REQUEST(xResourceReq);
REQUEST_SIZE_MATCH(xResourceReq);
- VERIFY_GEOMETRABLE (pDraw, stuff->id, client);
+ rc = dixLookupDrawable(&pDraw, stuff->id, client, M_ANY, DixUnknownAccess);
+ if (rc != Success)
+ return rc;
+
rep.type = X_Reply;
rep.length = 0;
rep.sequenceNumber = client->sequence;
diff --git a/Xext/shm.c b/Xext/shm.c
index 049c746d6..4e733197c 100644
--- a/Xext/shm.c
+++ b/Xext/shm.c
@@ -727,7 +727,7 @@ ProcPanoramiXShmCreatePixmap(
PixmapPtr pMap = NULL;
DrawablePtr pDraw;
DepthPtr pDepth;
- int i, j, result;
+ int i, j, result, rc;
ShmDescPtr shmdesc;
REQUEST(xShmCreatePixmapReq);
PanoramiXRes *newPix;
@@ -737,7 +737,11 @@ ProcPanoramiXShmCreatePixmap(
if (!sharedPixmaps)
return BadImplementation;
LEGAL_NEW_RESOURCE(stuff->pid, client);
- VERIFY_GEOMETRABLE(pDraw, stuff->drawable, client);
+ rc = dixLookupDrawable(&pDraw, stuff->drawable, client, M_ANY,
+ DixUnknownAccess);
+ if (rc != Success)
+ return rc;
+
VERIFY_SHMPTR(stuff->shmseg, stuff->offset, TRUE, shmdesc, client);
if (!stuff->width || !stuff->height)
{
@@ -1052,9 +1056,9 @@ ProcShmCreatePixmap(client)
register ClientPtr client;
{
PixmapPtr pMap;
- register DrawablePtr pDraw;
+ DrawablePtr pDraw;
DepthPtr pDepth;
- register int i;
+ register int i, rc;
ShmDescPtr shmdesc;
REQUEST(xShmCreatePixmapReq);
@@ -1063,7 +1067,11 @@ ProcShmCreatePixmap(client)
if (!sharedPixmaps)
return BadImplementation;
LEGAL_NEW_RESOURCE(stuff->pid, client);
- VERIFY_GEOMETRABLE(pDraw, stuff->drawable, client);
+ rc = dixLookupDrawable(&pDraw, stuff->drawable, client, M_ANY,
+ DixUnknownAccess);
+ if (rc != Success)
+ return rc;
+
VERIFY_SHMPTR(stuff->shmseg, stuff->offset, TRUE, shmdesc, client);
if (!stuff->width || !stuff->height)
{
diff --git a/Xext/xf86bigfont.c b/Xext/xf86bigfont.c
index 44647060a..f50481f78 100644
--- a/Xext/xf86bigfont.c
+++ b/Xext/xf86bigfont.c
@@ -447,7 +447,6 @@ ProcXF86BigfontQueryFont(
pFont = (FontPtr)SecurityLookupIDByType(client, stuff->id, RT_FONT,
DixReadAccess);
if (!pFont) {
- /* can't use VERIFY_GC because it might return BadGC */
GC *pGC = (GC *) SecurityLookupIDByType(client, stuff->id, RT_GC,
DixReadAccess);
if (!pGC) {
diff --git a/dix/dispatch.c b/dix/dispatch.c
index 8134cd5a5..a5a1d0374 100644
--- a/dix/dispatch.c
+++ b/dix/dispatch.c
@@ -1385,7 +1385,6 @@ ProcQueryFont(register ClientPtr client)
DixReadAccess);
if (!pFont)
{
- /* can't use VERIFY_GC because it might return BadGC */
pGC = (GC *) SecurityLookupIDByType(client, stuff->id, RT_GC,
DixReadAccess);
if (!pGC)