summaryrefslogtreecommitdiff
path: root/dri3
diff options
context:
space:
mode:
Diffstat (limited to 'dri3')
-rw-r--r--dri3/dri3_request.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/dri3/dri3_request.c b/dri3/dri3_request.c
index 2b3622148..35548b6d2 100644
--- a/dri3/dri3_request.c
+++ b/dri3/dri3_request.c
@@ -178,8 +178,8 @@ proc_dri3_pixmap_from_buffer(ClientPtr client)
(*drawable->pScreen->DestroyPixmap) (pixmap);
return rc;
}
- if (AddResource(stuff->pixmap, RT_PIXMAP, (void *) pixmap))
- return Success;
+ if (!AddResource(stuff->pixmap, RT_PIXMAP, (void *) pixmap))
+ return BadAlloc;
return Success;
}