summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Xext/shm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Xext/shm.c b/Xext/shm.c
index 125000f5f..1b622e353 100644
--- a/Xext/shm.c
+++ b/Xext/shm.c
@@ -991,7 +991,7 @@ ProcPanoramiXShmCreatePixmap(ClientPtr client)
RT_PIXMAP, pMap, RT_NONE, NULL, DixCreateAccess);
if (result != Success) {
pDraw->pScreen->DestroyPixmap(pMap);
- return result;
+ break;
}
dixSetPrivate(&pMap->devPrivates, shmPixmapPrivateKey, shmdesc);
shmdesc->refcnt++;
@@ -1008,7 +1008,7 @@ ProcPanoramiXShmCreatePixmap(ClientPtr client)
}
}
- if (result == BadAlloc) {
+ if (result != Success) {
while (j--)
FreeResource(newPix->info[j].id, RT_NONE);
free(newPix);