quartz/tests: Use proper method macros.
This commit is contained in:
parent
39bee356ee
commit
1552e22b0b
|
@ -227,7 +227,7 @@ static void test_threads(void)
|
|||
ok(hr == E_NOINTERFACE,
|
||||
"Avi splitter returns unexpected error: %08x\n", hr);
|
||||
if (pfile)
|
||||
IUnknown_Release(pfile);
|
||||
IFileSourceFilter_Release(pfile);
|
||||
pfile = NULL;
|
||||
|
||||
hr = CoCreateInstance(&CLSID_AsyncReader, NULL, CLSCTX_INPROC_SERVER,
|
||||
|
@ -236,7 +236,7 @@ static void test_threads(void)
|
|||
if (hr != S_OK)
|
||||
goto fail;
|
||||
|
||||
hr = IUnknown_QueryInterface(preader, &IID_IFileSourceFilter,
|
||||
hr = IBaseFilter_QueryInterface(preader, &IID_IFileSourceFilter,
|
||||
(void**)&pfile);
|
||||
ok(hr == S_OK, "Could not get IFileSourceFilter: %08x\n", hr);
|
||||
if (hr != S_OK)
|
||||
|
@ -265,7 +265,7 @@ static void test_threads(void)
|
|||
if (hr != S_OK)
|
||||
goto fail;
|
||||
|
||||
IUnknown_Release(enumpins);
|
||||
IEnumPins_Release(enumpins);
|
||||
enumpins = NULL;
|
||||
|
||||
hr = IBaseFilter_EnumPins(pavi, &enumpins);
|
||||
|
@ -292,7 +292,7 @@ static void test_threads(void)
|
|||
ok(curlevel == expected,
|
||||
"The thread count should be %d not %d\n", expected, curlevel);
|
||||
|
||||
IUnknown_Release(avipin);
|
||||
IPin_Release(avipin);
|
||||
avipin = NULL;
|
||||
|
||||
IEnumPins_Reset(enumpins);
|
||||
|
@ -334,12 +334,12 @@ static void test_threads(void)
|
|||
++expected;
|
||||
}
|
||||
|
||||
IUnknown_Release(avipin);
|
||||
IPin_Release(avipin);
|
||||
avipin = NULL;
|
||||
}
|
||||
|
||||
if (avipin)
|
||||
IUnknown_Release(avipin);
|
||||
IPin_Release(avipin);
|
||||
avipin = NULL;
|
||||
|
||||
if (hr != S_OK)
|
||||
|
@ -414,10 +414,10 @@ fail:
|
|||
if (hr != S_OK)
|
||||
skip("Prerequisites not matched, skipping remainder of test\n");
|
||||
if (enumpins)
|
||||
IUnknown_Release(enumpins);
|
||||
IEnumPins_Release(enumpins);
|
||||
|
||||
if (avipin)
|
||||
IUnknown_Release(avipin);
|
||||
IPin_Release(avipin);
|
||||
if (filepin)
|
||||
{
|
||||
IPin *to = NULL;
|
||||
|
@ -428,15 +428,15 @@ fail:
|
|||
IPin_Disconnect(filepin);
|
||||
IPin_Disconnect(to);
|
||||
}
|
||||
IUnknown_Release(filepin);
|
||||
IPin_Release(filepin);
|
||||
}
|
||||
|
||||
if (preader)
|
||||
IUnknown_Release(preader);
|
||||
IBaseFilter_Release(preader);
|
||||
if (pavi)
|
||||
IUnknown_Release(pavi);
|
||||
IBaseFilter_Release(pavi);
|
||||
if (pfile)
|
||||
IUnknown_Release(pfile);
|
||||
IFileSourceFilter_Release(pfile);
|
||||
|
||||
curlevel = count_threads();
|
||||
todo_wine
|
||||
|
|
|
@ -33,7 +33,7 @@
|
|||
ok(ppv != NULL, "Pointer is NULL\n");
|
||||
|
||||
#define RELEASE_EXPECT(iface, num) if (iface) { \
|
||||
hr = IUnknown_Release(iface); \
|
||||
hr = IUnknown_Release((IUnknown*)iface); \
|
||||
ok(hr == num, "IUnknown_Release should return %d, got %d\n", num, hr); \
|
||||
}
|
||||
|
||||
|
|
|
@ -236,7 +236,7 @@ static void test_graph_builder_addfilter(void)
|
|||
|
||||
hr = IGraphBuilder_AddFilter(pgraph, pF, NULL);
|
||||
ok(hr == S_OK, "IGraphBuilder_AddFilter returned: %x\n", hr);
|
||||
IMediaFilter_Release(pF);
|
||||
IBaseFilter_Release(pF);
|
||||
}
|
||||
|
||||
static void test_mediacontrol(void)
|
||||
|
@ -247,26 +247,26 @@ static void test_mediacontrol(void)
|
|||
IMediaFilter *filter = NULL;
|
||||
IMediaControl *control = NULL;
|
||||
|
||||
IFilterGraph2_SetDefaultSyncSource(pgraph);
|
||||
hr = IFilterGraph2_QueryInterface(pgraph, &IID_IMediaSeeking, (void**) &seeking);
|
||||
IGraphBuilder_SetDefaultSyncSource(pgraph);
|
||||
hr = IGraphBuilder_QueryInterface(pgraph, &IID_IMediaSeeking, (void**) &seeking);
|
||||
ok(hr == S_OK, "QueryInterface IMediaControl failed: %08x\n", hr);
|
||||
if (FAILED(hr))
|
||||
return;
|
||||
|
||||
hr = IFilterGraph2_QueryInterface(pgraph, &IID_IMediaFilter, (void**) &filter);
|
||||
hr = IGraphBuilder_QueryInterface(pgraph, &IID_IMediaFilter, (void**) &filter);
|
||||
ok(hr == S_OK, "QueryInterface IMediaFilter failed: %08x\n", hr);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
IUnknown_Release(seeking);
|
||||
IMediaSeeking_Release(seeking);
|
||||
return;
|
||||
}
|
||||
|
||||
hr = IFilterGraph2_QueryInterface(pgraph, &IID_IMediaControl, (void**) &control);
|
||||
hr = IGraphBuilder_QueryInterface(pgraph, &IID_IMediaControl, (void**) &control);
|
||||
ok(hr == S_OK, "QueryInterface IMediaControl failed: %08x\n", hr);
|
||||
if (FAILED(hr))
|
||||
{
|
||||
IUnknown_Release(seeking);
|
||||
IUnknown_Release(filter);
|
||||
IMediaSeeking_Release(seeking);
|
||||
IMediaFilter_Release(filter);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -288,9 +288,9 @@ static void test_mediacontrol(void)
|
|||
hr = IMediaControl_GetState(control, 1000, NULL);
|
||||
ok(hr == E_POINTER, "GetState expected %08x, got %08x\n", E_POINTER, hr);
|
||||
|
||||
IUnknown_Release(control);
|
||||
IUnknown_Release(seeking);
|
||||
IUnknown_Release(filter);
|
||||
IMediaControl_Release(control);
|
||||
IMediaSeeking_Release(seeking);
|
||||
IMediaFilter_Release(filter);
|
||||
releasefiltergraph();
|
||||
}
|
||||
|
||||
|
|
|
@ -69,9 +69,9 @@ static void CommitDecommitTest(void)
|
|||
|
||||
hr = IMemAllocator_GetBuffer(pMemAllocator, &sample2, NULL, NULL, 0);
|
||||
ok(hr==S_OK, "Could not get a buffer: %x\n", hr);
|
||||
IUnknown_Release(sample);
|
||||
IMediaSample_Release(sample);
|
||||
if (sample2)
|
||||
IUnknown_Release(sample2);
|
||||
IMediaSample_Release(sample2);
|
||||
|
||||
hr = IMemAllocator_Decommit(pMemAllocator);
|
||||
ok(hr==S_OK, "Cecommit returned: %x\n", hr);
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
ok(ppv != NULL, "Pointer is NULL\n");
|
||||
|
||||
#define RELEASE_EXPECT(iface, num) if (iface) { \
|
||||
hr = IUnknown_Release(iface); \
|
||||
hr = IUnknown_Release((IUnknown*)iface); \
|
||||
ok(hr == num, "IUnknown_Release should return %d, got %d\n", num, hr); \
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue