dri3: return an error if AddResource fails
Reviewed-by: Rémi Cardona <remi@gentoo.org> Signed-off-by: Julien Cristau <jcristau@debian.org>
This commit is contained in:
parent
119d5c0e2f
commit
ac97fb2b80
|
@ -178,8 +178,8 @@ proc_dri3_pixmap_from_buffer(ClientPtr client)
|
||||||
(*drawable->pScreen->DestroyPixmap) (pixmap);
|
(*drawable->pScreen->DestroyPixmap) (pixmap);
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
if (AddResource(stuff->pixmap, RT_PIXMAP, (void *) pixmap))
|
if (!AddResource(stuff->pixmap, RT_PIXMAP, (void *) pixmap))
|
||||||
return Success;
|
return BadAlloc;
|
||||||
|
|
||||||
return Success;
|
return Success;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user