aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAxel Davy <[email protected]>2014-11-23 11:44:59 +0100
committerAxel Davy <[email protected]>2014-12-03 16:39:24 +0100
commitca0588d1a1e61404687fb6a6bc4857819fa46e2e (patch)
treebfcc1ee7faa8e9b3d9ac4029562129d22fa213db
parentb0302a95ece423f18a710dea391686e1a6557716 (diff)
st/nine: Queries: return S_FALSE instead of INVALIDCALL when in building query state
It is the same behaviour as wine has. Reviewed-by: Ilia Mirkin <[email protected]> Reviewed-by: David Heidelberg <[email protected]> Signed-off-by: Axel Davy <[email protected]>
-rw-r--r--src/gallium/state_trackers/nine/query9.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/nine/query9.c b/src/gallium/state_trackers/nine/query9.c
index 17c36e510fc..b74a707e3f3 100644
--- a/src/gallium/state_trackers/nine/query9.c
+++ b/src/gallium/state_trackers/nine/query9.c
@@ -205,7 +205,10 @@ NineQuery9_GetData( struct NineQuery9 *This,
DBG("This=%p pData=%p dwSize=%d dwGetDataFlags=%d\n",
This, pData, dwSize, dwGetDataFlags);
- user_assert(This->state != NINE_QUERY_STATE_RUNNING, D3DERR_INVALIDCALL);
+ /* according to spec we should return D3DERR_INVALIDCALL here, but
+ * wine returns S_FALSE because it is apparently the behaviour
+ * on windows */
+ user_assert(This->state != NINE_QUERY_STATE_RUNNING, S_FALSE);
user_assert(dwSize == 0 || pData, D3DERR_INVALIDCALL);
user_assert(dwGetDataFlags == 0 ||
dwGetDataFlags == D3DGETDATA_FLUSH, D3DERR_INVALIDCALL);