[PATCH 5/5] d3d10core: Release the wined3d query in d3d10_query_Release() (Valgrind).
Henri Verbeet
hverbeet at codeweavers.com
Tue Apr 28 13:30:55 CDT 2015
---
dlls/d3d10core/async.c | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/dlls/d3d10core/async.c b/dlls/d3d10core/async.c
index d6c3d81..f6886a7 100644
--- a/dlls/d3d10core/async.c
+++ b/dlls/d3d10core/async.c
@@ -66,16 +66,17 @@ static ULONG STDMETHODCALLTYPE d3d10_query_AddRef(ID3D10Query *iface)
static ULONG STDMETHODCALLTYPE d3d10_query_Release(ID3D10Query *iface)
{
- struct d3d10_query *This = impl_from_ID3D10Query(iface);
- ULONG refcount = InterlockedDecrement(&This->refcount);
+ struct d3d10_query *query = impl_from_ID3D10Query(iface);
+ ULONG refcount = InterlockedDecrement(&query->refcount);
- TRACE("%p decreasing refcount to %u.\n", This, refcount);
+ TRACE("%p decreasing refcount to %u.\n", query, refcount);
if (!refcount)
{
- ID3D10Device1_Release(This->device);
- wined3d_private_store_cleanup(&This->private_store);
- HeapFree(GetProcessHeap(), 0, This);
+ ID3D10Device1_Release(query->device);
+ wined3d_query_decref(query->wined3d_query);
+ wined3d_private_store_cleanup(&query->private_store);
+ HeapFree(GetProcessHeap(), 0, query);
}
return refcount;
--
1.7.10.4
More information about the wine-patches
mailing list