projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
777f352
)
glx: Fix another use-after-free problem
author
Kristian Høgsberg
<krh@bitplanet.net>
Thu, 9 Sep 2010 12:06:40 +0000
(08:06 -0400)
committer
Kristian Høgsberg
<krh@bitplanet.net>
Thu, 9 Sep 2010 12:06:51 +0000
(08:06 -0400)
src/glx/glx_pbuffer.c
patch
|
blob
|
history
diff --git
a/src/glx/glx_pbuffer.c
b/src/glx/glx_pbuffer.c
index d1cb66b87cac825d6fa0f3b8b40775f8c6aebb83..34892e8b1a2bcb34573dbfbc1651254a30c05066 100644
(file)
--- a/
src/glx/glx_pbuffer.c
+++ b/
src/glx/glx_pbuffer.c
@@
-220,12
+220,14
@@
DestroyDRIDrawable(Display *dpy, GLXDrawable drawable, int destroy_xdrawable)
{
struct glx_display *const priv = __glXInitialize(dpy);
__GLXDRIdrawable *pdraw = GetGLXDRIDrawable(dpy, drawable);
+ XID xid;
if (pdraw != NULL) {
+ xid = pdraw->xDrawable;
(*pdraw->destroyDrawable) (pdraw);
__glxHashDelete(priv->drawHash, drawable);
if (destroy_xdrawable)
- XFreePixmap(p
draw->psc->dpy, pdraw->xDrawable
);
+ XFreePixmap(p
riv->dpy, xid
);
}
}