From 681469685b22ba7fedfbc808498028b518b890a0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Stefan=20D=C3=B6singer?= <stefan@codeweavers.com>
Date: Mon, 5 Aug 2013 13:07:42 +0200
Subject: wined3d: Don't reset the query state if it doesn't have a ctx

The CS recreates occlusion queries and changes the context variable.
This leads to incorrect query results.

TODO: Before sending, find out why the line was there in the first place
and if it is needed with the multithreaded and/or singlethreaded CS.
---
 dlls/wined3d/query.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/dlls/wined3d/query.c b/dlls/wined3d/query.c
index a42a1bd..39d663a 100644
--- a/dlls/wined3d/query.c
+++ b/dlls/wined3d/query.c
@@ -321,9 +321,6 @@ static HRESULT wined3d_occlusion_query_ops_get_data(struct wined3d_query *query,
     struct wined3d_occlusion_query *oq = query->extendedData;
     GLuint samples;
 
-    if (!oq->context)
-        query->state = QUERY_CREATED;
-
     if (query->state == QUERY_CREATED)
     {
         /* D3D allows GetData on a new query, OpenGL doesn't. So just invent the data ourselves */
-- 
2.1.3

