summaryrefslogtreecommitdiff
path: root/hw/dmx
diff options
context:
space:
mode:
authorJulien Cristau <jcristau@debian.org>2016-03-07 23:20:29 +0100
committerAdam Jackson <ajax@redhat.com>2016-03-08 10:19:51 -0500
commit164753f158e78f615f903467bfd234d7c58244ef (patch)
treeea240252c78305f7d8a3d5e4dd659837e92581f7 /hw/dmx
parent59b9c3d5e4bf05aeaaac2ee4ea12c301a67aae2c (diff)
dmx/glxProxy: don't free the glx pixmap twice if AddResource fails
Reviewed-by: RĂ©mi Cardona <remi@gentoo.org> Signed-off-by: Julien Cristau <jcristau@debian.org>
Diffstat (limited to 'hw/dmx')
-rw-r--r--hw/dmx/glxProxy/glxcmds.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/hw/dmx/glxProxy/glxcmds.c b/hw/dmx/glxProxy/glxcmds.c
index ddcb98135..a77d556db 100644
--- a/hw/dmx/glxProxy/glxcmds.c
+++ b/hw/dmx/glxProxy/glxcmds.c
@@ -2010,11 +2010,8 @@ CreateGLXPixmap(__GLXclientState * cl,
XFlush(dpy);
}
- if (!(AddResource(glxpixmapId, __glXPixmapRes, pGlxPixmap))) {
- free(pGlxPixmap->be_xids);
- free(pGlxPixmap);
+ if (!(AddResource(glxpixmapId, __glXPixmapRes, pGlxPixmap)))
return BadAlloc;
- }
return Success;
}