diff options
author | Andy Skinner <Andy.Skinner@mathworks.com> | 2011-02-11 07:31:25 -0800 |
---|---|---|
committer | Brian Paul <brianp@vmware.com> | 2011-02-22 12:47:17 -0700 |
commit | 90e227f0791cb585dc4e4e1f71e32c67f5e20436 (patch) | |
tree | 5f7e2685493684d6d051e93dc8375f5674461bba /src/mesa/drivers/x11/xm_api.c | |
parent | 2bfc23fb86964e4153f57f2a56248760f6066033 (diff) |
xlib: pass Display pointer to XMesaGarbageCollect()
Fixes an issue when different displays are used on different threads.
Signed-off-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'src/mesa/drivers/x11/xm_api.c')
-rw-r--r-- | src/mesa/drivers/x11/xm_api.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/drivers/x11/xm_api.c b/src/mesa/drivers/x11/xm_api.c index cb71b344a2..aad902d1ed 100644 --- a/src/mesa/drivers/x11/xm_api.c +++ b/src/mesa/drivers/x11/xm_api.c @@ -2064,12 +2064,12 @@ void xmesa_destroy_buffers_on_display(XMesaDisplay *dpy) * Look for XMesaBuffers whose X window has been destroyed. * Deallocate any such XMesaBuffers. */ -void XMesaGarbageCollect( void ) +void XMesaGarbageCollect( XMesaDisplay* dpy ) { XMesaBuffer b, next; for (b=XMesaBufferList; b; b=next) { next = b->Next; - if (b->display && b->frontxrb->drawable && b->type == WINDOW) { + if (b->display && b->display == dpy && b->frontxrb->drawable && b->type == WINDOW) { XSync(b->display, False); if (!window_exists( b->display, b->frontxrb->drawable )) { /* found a dead window, free the ancillary info */ |