summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIlia Mirkin <imirkin@alum.mit.edu>2015-12-19 15:29:14 -0500
committerEmil Velikov <emil.l.velikov@gmail.com>2016-01-08 12:05:26 +0200
commit56318a9899ee116eb9a0c38eff95d33c473457fb (patch)
treeff6e693ceec6210b54034e87648f6766a68ecb8b
parent28680b36e89826df0f7c30c71d05de0a2102f5db (diff)
glx/dri3: a drawable might not be bound at wait time
A trace of Alien Isolation hit this on nouveau. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-and-Tested-by: Michel Dänzer <michel.daenzer@amd.com> Cc: "11.0 11.1" <mesa-stable@lists.freedesktop.org> (cherry picked from commit f7b71451231c75c36771e8b7b0d78f05e0d50f65)
-rw-r--r--src/glx/dri3_glx.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/glx/dri3_glx.c b/src/glx/dri3_glx.c
index ee24312673..8bdbb9caf5 100644
--- a/src/glx/dri3_glx.c
+++ b/src/glx/dri3_glx.c
@@ -437,7 +437,8 @@ dri3_wait_x(struct glx_context *gc)
struct dri3_drawable *priv = (struct dri3_drawable *)
GetGLXDRIDrawable(gc->currentDpy, gc->currentDrawable);
- loader_dri3_wait_x(&priv->loader_drawable);
+ if (priv)
+ loader_dri3_wait_x(&priv->loader_drawable);
}
static void
@@ -446,7 +447,8 @@ dri3_wait_gl(struct glx_context *gc)
struct dri3_drawable *priv = (struct dri3_drawable *)
GetGLXDRIDrawable(gc->currentDpy, gc->currentDrawable);
- loader_dri3_wait_gl(&priv->loader_drawable);
+ if (priv)
+ loader_dri3_wait_gl(&priv->loader_drawable);
}
/**