[v3 2/3] d3dx9/tests: Add test for releasing pool before effects referencing it.
Paul Gofman
gofmanp at gmail.com
Wed Apr 26 04:21:03 CDT 2017
Signed-off-by: Paul Gofman <gofmanp at gmail.com>
---
v3:
- added patch.
---
dlls/d3dx9_36/tests/effect.c | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/dlls/d3dx9_36/tests/effect.c b/dlls/d3dx9_36/tests/effect.c
index 9a436d5..dbf91c4 100644
--- a/dlls/d3dx9_36/tests/effect.c
+++ b/dlls/d3dx9_36/tests/effect.c
@@ -6130,6 +6130,21 @@ static void test_effect_shared_parameters(IDirect3DDevice9 *device)
hr = effect2->lpVtbl->End(effect2);
ok(hr == D3D_OK, "Got result %#x.\n", hr);
+ if (0)
+ {
+ refcount = pool->lpVtbl->Release(pool);
+ ok(refcount == 2, "Unexpected refcount %u.\n", refcount);
+
+ refcount = pool->lpVtbl->Release(pool);
+ ok(refcount == 1, "Unexpected refcount %u.\n", refcount);
+
+ refcount = pool->lpVtbl->Release(pool);
+ ok(!refcount, "Unexpected refcount %u.\n", refcount);
+
+ /* Native d3dx crashes in GetFloat(). */
+ effect2->lpVtbl->GetFloat(effect2, "arr2[0]", &fvect.x);
+ }
+
effect1->lpVtbl->Release(effect1);
effect2->lpVtbl->Release(effect2);
--
2.9.3
More information about the wine-patches
mailing list