[PATCH 1/6] windows.media.speech/tests: Fix some uses after release.
Bernhard Kölbl
besentv at gmail.com
Wed Apr 20 14:34:08 CDT 2022
Signed-off-by: Bernhard Kölbl <besentv at gmail.com>
---
dlls/windows.media.speech/tests/speech.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/dlls/windows.media.speech/tests/speech.c b/dlls/windows.media.speech/tests/speech.c
index ef75178f8c1..e4d65d3afd4 100644
--- a/dlls/windows.media.speech/tests/speech.c
+++ b/dlls/windows.media.speech/tests/speech.c
@@ -858,6 +858,8 @@ static void test_SpeechRecognizer(void)
goto done;
}
+ check_interface(factory, &IID_IAgileObject, TRUE);
+
hr = IActivationFactory_QueryInterface(factory, &IID_ISpeechRecognizerFactory, (void **)&sr_factory);
ok(hr == S_OK, "IActivationFactory_QueryInterface IID_ISpeechRecognizer failed, hr %#lx.\n", hr);
@@ -901,7 +903,6 @@ static void test_SpeechRecognizer(void)
if (hr == S_OK)
{
check_refcount(inspectable, 1);
- check_interface(factory, &IID_IAgileObject, TRUE);
hr = IInspectable_QueryInterface(inspectable, &IID_ISpeechRecognizer, (void **)&recognizer);
ok(hr == S_OK, "Got unexpected hr %#lx.\n", hr);
@@ -1068,8 +1069,6 @@ static void test_SpeechRecognizer(void)
todo_wine ok(hr == S_OK, "IAsyncInfo_get_Status failed, hr %#lx.\n", hr);
todo_wine ok(async_status == Started || async_status == Completed, "Status was %#x.\n", async_status);
- IAsyncInfo_Release(info);
-
hr = IAsyncOperation_SpeechRecognitionCompilationResult_put_Completed(operation, &compilation_handler2.IAsyncHandler_Compilation_iface);
todo_wine ok(hr == S_OK, "Got unexpected hr %#lx.\n", hr);
@@ -1081,6 +1080,9 @@ static void test_SpeechRecognizer(void)
todo_wine ok(hr == S_OK, "IAsyncInfo_get_Status failed, hr %#lx.\n", hr);
todo_wine ok(async_status == Completed, "Status was %#x.\n", async_status);
+ ref = IAsyncInfo_Release(info);
+ todo_wine ok(ref == 1, "Got unexpected ref %lu.\n", ref);
+
skip_operation:
ref = IAsyncOperation_SpeechRecognitionCompilationResult_Release(operation);
ok(!ref, "Got unexpected ref %lu.\n", ref);
--
2.35.1
More information about the wine-devel
mailing list