mirror of
https://gitlab.freedesktop.org/xorg/xserver.git
synced 2026-05-05 20:28:19 +02:00
glx: Only take a Pixmap reference if creating the GLXPixmap succeeded
Reviewed-by: Julien Cristau <jcristau@debian.org> Signed-off-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
parent
7ecfab47eb
commit
75b362763c
1 changed files with 2 additions and 1 deletions
|
|
@ -1249,7 +1249,8 @@ DoCreateGLXPixmap(ClientPtr client, __GLXscreen * pGlxScreen,
|
|||
err = DoCreateGLXDrawable(client, pGlxScreen, config, pDraw, drawableId,
|
||||
glxDrawableId, GLX_DRAWABLE_PIXMAP);
|
||||
|
||||
((PixmapPtr) pDraw)->refcnt++;
|
||||
if (err == Success)
|
||||
((PixmapPtr) pDraw)->refcnt++;
|
||||
|
||||
return err;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue