From 3c1172f06636ff4aec24a6c68df937844da73a53 Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Sat, 29 Aug 2009 13:23:58 -0700 Subject: i965: Fix segfault with ARB_oq CheckQuery when results are already fetched. --- src/mesa/drivers/dri/i965/brw_queryobj.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/drivers/dri/i965/brw_queryobj.c b/src/mesa/drivers/dri/i965/brw_queryobj.c index f94aa9d..a195bc3 100644 --- a/src/mesa/drivers/dri/i965/brw_queryobj.c +++ b/src/mesa/drivers/dri/i965/brw_queryobj.c @@ -148,7 +148,7 @@ static void brw_check_query(GLcontext *ctx, struct gl_query_object *q) { struct brw_query_object *query = (struct brw_query_object *)q; - if (!drm_intel_bo_busy(query->bo)) { + if (query->bo == NULL || !drm_intel_bo_busy(query->bo)) { brw_queryobj_get_results(query); query->Base.Ready = GL_TRUE; } -- cgit v1.1