We test once above that the source does not use the existing allocator, but then implicitly release the allocator we are testing against (when the source assigns a new allocator to the sink). As a result, these ok() statements were testing that newly allocated allocators had a different address than the original allocator, which of course sometimes fails.
Since we don't need to perform this test more than once anyway, just get rid of the offending ok() statements.
From: Zebediah Figura zfigura@codeweavers.com
We test once above that the source does not use the existing allocator, but then implicitly release the allocator we are testing against (when the source assigns a new allocator to the sink). As a result, these ok() statements were testing that newly allocated allocators had a different address than the original allocator, which of course sometimes fails.
Since we don't need to perform this test more than once anyway, just get rid of the offending ok() statements. --- dlls/qcap/tests/audiorecord.c | 4 ---- 1 file changed, 4 deletions(-)
diff --git a/dlls/qcap/tests/audiorecord.c b/dlls/qcap/tests/audiorecord.c index ed6c54648d0..e0a130fefb3 100644 --- a/dlls/qcap/tests/audiorecord.c +++ b/dlls/qcap/tests/audiorecord.c @@ -705,8 +705,6 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control, hr = IFilterGraph2_ConnectDirect(graph, source, &testsink->sink.pin.IPin_iface, &mt); ok(hr == S_OK, "Got hr %#lx.\n", hr);
- todo_wine ok(testsink->sink.pAllocator && testsink->sink.pAllocator != allocator, - "Got unexpected allocator %p.\n", testsink->sink.pAllocator); hr = IMemAllocator_GetProperties(testsink->sink.pAllocator, &props); ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(props.cBuffers == req_props.cBuffers, "Got %ld buffers.\n", props.cBuffers); @@ -728,8 +726,6 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control, hr = IFilterGraph2_ConnectDirect(graph, source, &testsink->sink.pin.IPin_iface, &mt); ok(hr == S_OK, "Got hr %#lx.\n", hr);
- todo_wine ok(testsink->sink.pAllocator && testsink->sink.pAllocator != allocator, - "Got unexpected allocator %p.\n", testsink->sink.pAllocator); hr = IMemAllocator_GetProperties(testsink->sink.pAllocator, &props); ok(hr == S_OK, "Got hr %#lx.\n", hr); ok(props.cBuffers == 4, "Got %ld buffers.\n", props.cBuffers);