[PATCH v2 5/5] qedit/tests: Build without -DWINE_NO_LONG_TYPES.
Zebediah Figura
zfigura at codeweavers.com
Thu Mar 3 11:40:58 CST 2022
From: Eric Pouech <eric.pouech at gmail.com>
Signed-off-by: Eric Pouech <eric.pouech at gmail.com>
Signed-off-by: Zebediah Figura <zfigura at codeweavers.com>
---
v2: Fix subject; make some messages consistent while we're at it.
dlls/qedit/tests/Makefile.in | 1 -
dlls/qedit/tests/mediadet.c | 313 +++++++++++----------
dlls/qedit/tests/nullrenderer.c | 370 ++++++++++++-------------
dlls/qedit/tests/samplegrabber.c | 462 +++++++++++++++----------------
dlls/qedit/tests/timeline.c | 74 ++---
5 files changed, 609 insertions(+), 611 deletions(-)
diff --git a/dlls/qedit/tests/Makefile.in b/dlls/qedit/tests/Makefile.in
index 0b028674090..a1020f5052d 100644
--- a/dlls/qedit/tests/Makefile.in
+++ b/dlls/qedit/tests/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
TESTDLL = qedit.dll
IMPORTS = strmbase strmiids uuid oleaut32 ole32
diff --git a/dlls/qedit/tests/mediadet.c b/dlls/qedit/tests/mediadet.c
index dc83bb9a0a6..3202baca924 100644
--- a/dlls/qedit/tests/mediadet.c
+++ b/dlls/qedit/tests/mediadet.c
@@ -82,53 +82,53 @@ static void test_aggregation(void)
detector = (IMediaDet *)0xdeadbeef;
hr = CoCreateInstance(&CLSID_MediaDet, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IMediaDet, (void **)&detector);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!detector, "Got interface %p.\n", detector);
hr = CoCreateInstance(&CLSID_MediaDet, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IUnknown, (void **)&unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ok(unk != &test_outer, "Returned IUnknown should not be outer IUnknown.\n");
ref = get_refcount(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
ref = IUnknown_AddRef(unk);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ref = IUnknown_Release(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
hr = IUnknown_QueryInterface(unk, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == unk, "Got unexpected IUnknown %p.\n", unk2);
IUnknown_Release(unk2);
hr = IUnknown_QueryInterface(unk, &IID_IMediaDet, (void **)&detector);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaDet_QueryInterface(detector, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
hr = IMediaDet_QueryInterface(detector, &IID_IMediaDet, (void **)&detector2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(detector2 == (IMediaDet *)0xdeadbeef, "Got unexpected IMediaDet %p.\n", detector2);
hr = IUnknown_QueryInterface(unk, &test_iid, (void **)&unk2);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!unk2, "Got unexpected IUnknown %p.\n", unk2);
hr = IMediaDet_QueryInterface(detector, &test_iid, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
IMediaDet_Release(detector);
ref = IUnknown_Release(unk);
- ok(!ref, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(!ref, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
}
struct testfilter
@@ -448,15 +448,14 @@ static void test_mediadet(void)
HRESULT hr;
FILTER_INFO filter_info;
AM_MEDIA_TYPE mt, *pmt;
+ LONG index, ref, count;
IEnumMediaTypes *type;
IMediaDet *pM = NULL;
BSTR filename = NULL;
IBaseFilter *filter;
IEnumPins *enumpins;
- LONG nstrms = 0;
IUnknown *unk;
IPin *pin;
- LONG strm;
GUID guid;
BSTR bstr;
double fps;
@@ -466,185 +465,185 @@ static void test_mediadet(void)
/* test.avi has one video stream. */
hr = CoCreateInstance(&CLSID_MediaDet, NULL, CLSCTX_INPROC_SERVER,
&IID_IMediaDet, (LPVOID*)&pM);
- ok(hr == S_OK, "CoCreateInstance failed with %x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(pM != NULL, "pM is NULL\n");
filename = NULL;
hr = IMediaDet_get_Filename(pM, &filename);
/* Despite what MSDN claims, this returns S_OK. */
- ok(hr == S_OK, "IMediaDet_get_Filename failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(filename == NULL, "IMediaDet_get_Filename\n");
filename = (BSTR) -1;
hr = IMediaDet_get_Filename(pM, &filename);
/* Despite what MSDN claims, this returns S_OK. */
- ok(hr == S_OK, "IMediaDet_get_Filename failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(filename == NULL, "IMediaDet_get_Filename\n");
- nstrms = -1;
- hr = IMediaDet_get_OutputStreams(pM, &nstrms);
- ok(hr == E_INVALIDARG, "IMediaDet_get_OutputStreams failed: %08x\n", hr);
- ok(nstrms == -1, "IMediaDet_get_OutputStreams: nstrms is %i\n", nstrms);
+ count = -1;
+ hr = IMediaDet_get_OutputStreams(pM, &count);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
+ ok(count == -1, "Got %ld streams.\n", count);
- strm = -1;
+ index = -1;
/* The stream defaults to 0, even without a file! */
- hr = IMediaDet_get_CurrentStream(pM, &strm);
- ok(hr == S_OK, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
- ok(strm == 0, "IMediaDet_get_CurrentStream: strm is %i\n", strm);
+ hr = IMediaDet_get_CurrentStream(pM, &index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 0, "Got stream index %ld.\n", index);
hr = IMediaDet_get_CurrentStream(pM, NULL);
- ok(hr == E_POINTER, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
/* But put_CurrentStream doesn't. */
hr = IMediaDet_put_CurrentStream(pM, 0);
- ok(hr == E_INVALIDARG, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IMediaDet_put_CurrentStream(pM, -1);
- ok(hr == E_INVALIDARG, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamMediaType(pM, &mt);
- ok(hr == E_INVALIDARG, "IMediaDet_get_StreamMediaType failed: %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamMediaType(pM, NULL);
- ok(hr == E_POINTER, "IMediaDet_get_StreamMediaType failed: %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamType(pM, &guid);
- ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamType(pM, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamTypeB(pM, &bstr);
- ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamTypeB(pM, NULL);
- ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_Filter(pM, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
unk = (IUnknown*)0xdeadbeef;
hr = IMediaDet_get_Filter(pM, &unk);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
ok(!unk, "Got filter %p.\n", unk);
filename = SysAllocString(test_avi_filename);
hr = IMediaDet_put_Filename(pM, filename);
- ok(hr == S_OK, "IMediaDet_put_Filename failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
SysFreeString(filename);
- strm = -1;
+ index = -1;
/* The stream defaults to 0. */
- hr = IMediaDet_get_CurrentStream(pM, &strm);
- ok(hr == S_OK, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
- ok(strm == 0, "IMediaDet_get_CurrentStream: strm is %i\n", strm);
+ hr = IMediaDet_get_CurrentStream(pM, &index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 0, "Got stream index %ld.\n", index);
ZeroMemory(&mt, sizeof mt);
hr = IMediaDet_get_StreamMediaType(pM, &mt);
- ok(hr == S_OK, "IMediaDet_get_StreamMediaType failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
CoTaskMemFree(mt.pbFormat);
hr = IMediaDet_get_StreamType(pM, &guid);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(IsEqualGUID(&guid, &MEDIATYPE_Video), "Got major type %s.\n", debugstr_guid(&guid));
hr = IMediaDet_get_StreamTypeB(pM, &bstr);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(bstr, L"{73646976-0000-0010-8000-00AA00389B71}"),
"Got major type %s.\n", debugstr_w(bstr));
SysFreeString(bstr);
/* Even before get_OutputStreams. */
hr = IMediaDet_put_CurrentStream(pM, 1);
- ok(hr == E_INVALIDARG, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
- hr = IMediaDet_get_OutputStreams(pM, &nstrms);
- ok(hr == S_OK, "IMediaDet_get_OutputStreams failed: %08x\n", hr);
- ok(nstrms == 1, "IMediaDet_get_OutputStreams: nstrms is %i\n", nstrms);
+ hr = IMediaDet_get_OutputStreams(pM, &count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 1, "Got %ld streams.\n", count);
filename = NULL;
hr = IMediaDet_get_Filename(pM, &filename);
- ok(hr == S_OK, "IMediaDet_get_Filename failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(filename, test_avi_filename), "Expected filename %s, got %s.\n",
debugstr_w(test_avi_filename), debugstr_w(filename));
SysFreeString(filename);
hr = IMediaDet_get_Filename(pM, NULL);
- ok(hr == E_POINTER, "IMediaDet_get_Filename failed: %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
- strm = -1;
- hr = IMediaDet_get_CurrentStream(pM, &strm);
- ok(hr == S_OK, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
- ok(strm == 0, "IMediaDet_get_CurrentStream: strm is %i\n", strm);
+ index = -1;
+ hr = IMediaDet_get_CurrentStream(pM, &index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 0, "Got stream index %ld.\n", index);
hr = IMediaDet_get_CurrentStream(pM, NULL);
- ok(hr == E_POINTER, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMediaDet_put_CurrentStream(pM, -1);
- ok(hr == E_INVALIDARG, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IMediaDet_put_CurrentStream(pM, 1);
- ok(hr == E_INVALIDARG, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
/* Try again. */
- strm = -1;
- hr = IMediaDet_get_CurrentStream(pM, &strm);
- ok(hr == S_OK, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
- ok(strm == 0, "IMediaDet_get_CurrentStream: strm is %i\n", strm);
+ index = -1;
+ hr = IMediaDet_get_CurrentStream(pM, &index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 0, "Got stream index %ld.\n", index);
hr = IMediaDet_put_CurrentStream(pM, 0);
- ok(hr == S_OK, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
- strm = -1;
- hr = IMediaDet_get_CurrentStream(pM, &strm);
- ok(hr == S_OK, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
- ok(strm == 0, "IMediaDet_get_CurrentStream: strm is %i\n", strm);
+ index = -1;
+ hr = IMediaDet_get_CurrentStream(pM, &index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 0, "Got stream index %ld.\n", index);
ZeroMemory(&mt, sizeof mt);
hr = IMediaDet_get_StreamMediaType(pM, &mt);
- ok(hr == S_OK, "IMediaDet_get_StreamMediaType failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(IsEqualGUID(&mt.majortype, &MEDIATYPE_Video),
"IMediaDet_get_StreamMediaType\n");
CoTaskMemFree(mt.pbFormat);
hr = IMediaDet_get_StreamType(pM, &guid);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(IsEqualGUID(&guid, &MEDIATYPE_Video), "Got major type %s.\n", debugstr_guid(&guid));
hr = IMediaDet_get_StreamTypeB(pM, &bstr);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(bstr, L"{73646976-0000-0010-8000-00AA00389B71}"),
"Got major type %s.\n", debugstr_w(bstr));
SysFreeString(bstr);
hr = IMediaDet_get_FrameRate(pM, NULL);
- ok(hr == E_POINTER, "IMediaDet_get_FrameRate failed: %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_FrameRate(pM, &fps);
- ok(hr == S_OK, "IMediaDet_get_FrameRate failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(fps == 10.0, "IMediaDet_get_FrameRate: fps is %f\n", fps);
- hr = IMediaDet_Release(pM);
- ok(hr == 0, "IMediaDet_Release returned: %x\n", hr);
+ ref = IMediaDet_Release(pM);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
/* test_sound.avi has one video stream and one audio stream. */
hr = CoCreateInstance(&CLSID_MediaDet, NULL, CLSCTX_INPROC_SERVER,
&IID_IMediaDet, (LPVOID*)&pM);
- ok(hr == S_OK, "CoCreateInstance failed with %x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(pM != NULL, "pM is NULL\n");
filename = SysAllocString(test_sound_avi_filename);
hr = IMediaDet_put_Filename(pM, filename);
- ok(hr == S_OK, "IMediaDet_put_Filename failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
SysFreeString(filename);
- hr = IMediaDet_get_OutputStreams(pM, &nstrms);
- ok(hr == S_OK, "IMediaDet_get_OutputStreams failed: %08x\n", hr);
- ok(nstrms == 2, "IMediaDet_get_OutputStreams: nstrms is %i\n", nstrms);
+ hr = IMediaDet_get_OutputStreams(pM, &count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 2, "Got %ld streams.\n", count);
filename = NULL;
hr = IMediaDet_get_Filename(pM, &filename);
- ok(hr == S_OK, "IMediaDet_get_Filename failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(filename, test_sound_avi_filename), "Expected filename %s, got %s.\n",
debugstr_w(test_sound_avi_filename), debugstr_w(filename));
SysFreeString(filename);
@@ -656,16 +655,16 @@ static void test_mediadet(void)
for (i = 0; i < 2; ++i)
{
hr = IMediaDet_put_CurrentStream(pM, i);
- ok(hr == S_OK, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
- strm = -1;
- hr = IMediaDet_get_CurrentStream(pM, &strm);
- ok(hr == S_OK, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
- ok(strm == i, "IMediaDet_get_CurrentStream: strm is %i\n", strm);
+ index = -1;
+ hr = IMediaDet_get_CurrentStream(pM, &index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == i, "Got stream index %ld.\n", index);
ZeroMemory(&mt, sizeof mt);
hr = IMediaDet_get_StreamMediaType(pM, &mt);
- ok(hr == S_OK, "IMediaDet_get_StreamMediaType failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
flags += (IsEqualGUID(&mt.majortype, &MEDIATYPE_Video)
? 1
: (IsEqualGUID(&mt.majortype, &MEDIATYPE_Audio)
@@ -675,17 +674,17 @@ static void test_mediadet(void)
if (IsEqualGUID(&mt.majortype, &MEDIATYPE_Audio))
{
hr = IMediaDet_get_StreamType(pM, &guid);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(IsEqualGUID(&guid, &MEDIATYPE_Audio), "Got major type %s.\n", debugstr_guid(&guid));
hr = IMediaDet_get_StreamTypeB(pM, &bstr);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(bstr, L"{73647561-0000-0010-8000-00AA00389B71}"),
"Got major type %s.\n", debugstr_w(bstr));
SysFreeString(bstr);
hr = IMediaDet_get_FrameRate(pM, &fps);
- ok(hr == VFW_E_INVALIDMEDIATYPE, "IMediaDet_get_FrameRate failed: %08x\n", hr);
+ ok(hr == VFW_E_INVALIDMEDIATYPE, "Got hr %#lx.\n", hr);
}
CoTaskMemFree(mt.pbFormat);
@@ -693,29 +692,29 @@ static void test_mediadet(void)
ok(flags == 3, "IMediaDet_get_StreamMediaType: flags are %i\n", flags);
hr = IMediaDet_put_CurrentStream(pM, 2);
- ok(hr == E_INVALIDARG, "IMediaDet_put_CurrentStream failed: %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
- strm = -1;
- hr = IMediaDet_get_CurrentStream(pM, &strm);
- ok(hr == S_OK, "IMediaDet_get_CurrentStream failed: %08x\n", hr);
- ok(strm == 1, "IMediaDet_get_CurrentStream: strm is %i\n", strm);
+ index = -1;
+ hr = IMediaDet_get_CurrentStream(pM, &index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 1, "Got stream index %ld.\n", index);
unk = NULL;
hr = IMediaDet_get_Filter(pM, &unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!!unk, "Expected a non-NULL filter.\n");
hr = IUnknown_QueryInterface(unk, &IID_IBaseFilter, (void**)&filter);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IUnknown_Release(unk);
hr = IBaseFilter_EnumPins(filter, &enumpins);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enumpins, 1, &pin, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_EnumMediaTypes(pin, &type);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(type, 1, &pmt, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(IsEqualGUID(&pmt->majortype, &MEDIATYPE_Stream), "Got major type %s.\n",
debugstr_guid(&pmt->majortype));
IEnumMediaTypes_Release(type);
@@ -724,17 +723,17 @@ static void test_mediadet(void)
IPin_Release(pin);
hr = IEnumPins_Next(enumpins, 1, &pin, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
IEnumPins_Release(enumpins);
hr = IBaseFilter_QueryFilterInfo(filter, &filter_info);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(filter_info.achName, L"Source"), "Got name %s.\n", debugstr_w(filter_info.achName));
IFilterGraph_Release(filter_info.pGraph);
IBaseFilter_Release(filter);
- hr = IMediaDet_Release(pM);
- ok(hr == 0, "IMediaDet_Release returned: %x\n", hr);
+ ref = IMediaDet_Release(pM);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static void test_put_filter(void)
@@ -753,29 +752,29 @@ static void test_put_filter(void)
hr = CoCreateInstance(&CLSID_MediaDet, NULL, CLSCTX_INPROC_SERVER,
&IID_IMediaDet, (void **)&detector);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaDet_put_Filter(detector, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_Filter(detector, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamLength(detector, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_StreamLength(detector, &duration);
- ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
testfilter_init(&testfilter);
hr = IMediaDet_put_Filter(detector, &testfilter.filter.IUnknown_inner);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_Filter(detector, &unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!!unk, "Expected a non-NULL interface.\n");
hr = IUnknown_QueryInterface(unk, &IID_IBaseFilter, (void **)&filter);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(filter == &testfilter.filter.IBaseFilter_iface, "Expected the same filter.\n");
IBaseFilter_Release(filter);
IUnknown_Release(unk);
@@ -787,13 +786,13 @@ static void test_put_filter(void)
testfilter_init(&testfilter2);
hr = IMediaDet_put_Filter(detector, &testfilter2.filter.IUnknown_inner);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaDet_get_Filter(detector, &unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!!unk, "Expected a non-NULL interface.\n");
hr = IUnknown_QueryInterface(unk, &IID_IBaseFilter, (void **)&filter);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(filter == &testfilter2.filter.IBaseFilter_iface, "Expected the same filter.\n");
IBaseFilter_Release(filter);
IUnknown_Release(unk);
@@ -801,70 +800,70 @@ static void test_put_filter(void)
ok(testfilter2.filter.graph != graph, "Expected a different graph.\n");
ref = IFilterGraph_Release(graph);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ref = IBaseFilter_Release(&testfilter.filter.IBaseFilter_iface);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
count = 0xdeadbeef;
hr = IMediaDet_get_OutputStreams(detector, &count);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(count == 1, "Got %d streams.\n", count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 1, "Got %ld streams.\n", count);
index = 0xdeadbeef;
hr = IMediaDet_get_CurrentStream(detector, &index);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(index == 0, "Got stream %d.\n", index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 0, "Got stream %ld.\n", index);
filename = (BSTR)0xdeadbeef;
hr = IMediaDet_get_Filename(detector, &filename);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!filename, "Got filename %s.\n", debugstr_w(filename));
hr = IMediaDet_get_StreamLength(detector, &duration);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(duration == 4.2, "Got duration %.16e.\n", duration);
ref = IMediaDet_Release(detector);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ref = IBaseFilter_Release(&testfilter2.filter.IBaseFilter_iface);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
hr = CoCreateInstance(&CLSID_MediaDet, NULL, CLSCTX_INPROC_SERVER,
&IID_IMediaDet, (void **)&detector);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
filename = SysAllocString(test_sound_avi_filename);
hr = IMediaDet_put_Filename(detector, filename);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
SysFreeString(filename);
hr = IMediaDet_get_StreamMediaType(detector, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
FreeMediaType(&mt);
hr = IMediaDet_get_Filter(detector, &unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaDet_put_Filter(detector, unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IUnknown_Release(unk);
filename = (BSTR)0xdeadbeef;
hr = IMediaDet_get_Filename(detector, &filename);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!filename, "Got filename %s.\n", debugstr_w(filename));
count = 0xdeadbeef;
hr = IMediaDet_get_OutputStreams(detector, &count);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(count == 2, "Got %d streams.\n", count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 2, "Got %ld streams.\n", count);
index = 0xdeadbeef;
hr = IMediaDet_get_CurrentStream(detector, &index);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(index == 0, "Got stream %d.\n", index);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(index == 0, "Got stream %ld.\n", index);
ref = IMediaDet_Release(detector);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static HRESULT WINAPI ms_QueryInterface(IMediaSample *iface, REFIID riid,
@@ -1048,35 +1047,35 @@ static void test_samplegrabber(void)
/* Invalid RIID */
hr = CoCreateInstance(&CLSID_SampleGrabber, NULL, CLSCTX_INPROC_SERVER, &IID_IClassFactory,
(void**)&sg);
- ok(hr == E_NOINTERFACE, "SampleGrabber create failed: %08x, expected E_NOINTERFACE\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
hr = CoCreateInstance(&CLSID_SampleGrabber, NULL, CLSCTX_INPROC_SERVER, &IID_ISampleGrabber,
(void**)&sg);
- ok(hr == S_OK, "SampleGrabber create failed: %08x, expected S_OK\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = ISampleGrabber_QueryInterface(sg, &IID_IBaseFilter, (void**)&bf);
- ok(hr == S_OK, "QueryInterface for IID_IBaseFilter failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = ISampleGrabber_SetCallback(sg, &my_sg_cb, 0);
- ok(hr == S_OK, "SetCallback failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IBaseFilter_GetState(bf, 100, &fstate);
- ok(hr == S_OK, "Failed to get filter state: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(fstate == State_Stopped, "Got wrong filter state: %u\n", fstate);
hr = IBaseFilter_EnumPins(bf, &pins);
- ok(hr == S_OK, "EnumPins create failed: %08x, expected S_OK\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(pins, 1, &pin, NULL);
- ok(hr == S_OK, "Next failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IEnumPins_Release(pins);
hr = IPin_QueryInterface(pin, &IID_IMemInputPin, (void**)&inpin);
- ok(hr == S_OK, "QueryInterface(IMemInputPin) failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemInputPin_Receive(inpin, &my_sample);
- ok(hr == S_OK, "Receive failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(samplecb_called == TRUE, "SampleCB should have been called\n");
IMemInputPin_Release(inpin);
@@ -1095,22 +1094,22 @@ static void test_COM_sg_enumpins(void)
hr = CoCreateInstance(&CLSID_SampleGrabber, NULL, CLSCTX_INPROC_SERVER, &IID_IBaseFilter,
(void**)&bf);
- ok(hr == S_OK, "SampleGrabber create failed: %08x, expected S_OK\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IBaseFilter_EnumPins(bf, &pins);
- ok(hr == S_OK, "EnumPins create failed: %08x, expected S_OK\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
/* Same refcount for all EnumPins interfaces */
refcount = IEnumPins_AddRef(pins);
- ok(refcount == 2, "refcount == %u, expected 2\n", refcount);
+ ok(refcount == 2, "refcount == %lu, expected 2\n", refcount);
hr = IEnumPins_QueryInterface(pins, &IID_IEnumPins, (void**)&pins2);
- ok(hr == S_OK, "QueryInterface for IID_IEnumPins failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(pins == pins2, "QueryInterface for self failed (%p != %p)\n", pins, pins2);
IEnumPins_Release(pins2);
hr = IEnumPins_QueryInterface(pins, &IID_IUnknown, (void**)&unk);
- ok(hr == S_OK, "QueryInterface for IID_IUnknown failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
refcount = IUnknown_AddRef(unk);
- ok(refcount == 4, "refcount == %u, expected 4\n", refcount);
+ ok(refcount == 4, "refcount == %lu, expected 4\n", refcount);
refcount = IUnknown_Release(unk);
while (IEnumPins_Release(pins));
@@ -1135,7 +1134,7 @@ START_TEST(mediadet)
&IID_IMediaDet, (void **)&detector)))
{
/* qedit.dll does not exist on 2003. */
- win_skip("Failed to create media detector object, hr %#x.\n", hr);
+ win_skip("Failed to create media detector object, hr %#lx.\n", hr);
return;
}
IMediaDet_Release(detector);
@@ -1147,9 +1146,9 @@ START_TEST(mediadet)
test_COM_sg_enumpins();
ret = DeleteFileW(test_avi_filename);
- ok(ret, "Failed to delete file, error %u.\n", GetLastError());
+ ok(ret, "Failed to delete file, error %lu.\n", GetLastError());
ret = DeleteFileW(test_sound_avi_filename);
- ok(ret, "Failed to delete file, error %u.\n", GetLastError());
+ ok(ret, "Failed to delete file, error %lu.\n", GetLastError());
CoUninitialize();
}
diff --git a/dlls/qedit/tests/nullrenderer.c b/dlls/qedit/tests/nullrenderer.c
index cfbf1d37c2f..afc86e10d34 100644
--- a/dlls/qedit/tests/nullrenderer.c
+++ b/dlls/qedit/tests/nullrenderer.c
@@ -28,7 +28,7 @@ static IBaseFilter *create_null_renderer(void)
IBaseFilter *filter = NULL;
HRESULT hr = CoCreateInstance(&CLSID_NullRenderer, NULL, CLSCTX_INPROC_SERVER,
&IID_IBaseFilter, (void **)&filter);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
return filter;
}
@@ -37,7 +37,7 @@ static IFilterGraph2 *create_graph(void)
IFilterGraph2 *ret;
HRESULT hr;
hr = CoCreateInstance(&CLSID_FilterGraph, NULL, CLSCTX_INPROC_SERVER, &IID_IFilterGraph2, (void **)&ret);
- ok(hr == S_OK, "Failed to create FilterGraph: %#x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
return ret;
}
@@ -58,7 +58,7 @@ static void check_interface_(unsigned int line, void *iface_ptr, REFIID iid, BOO
expected_hr = supported ? S_OK : E_NOINTERFACE;
hr = IUnknown_QueryInterface(iface, iid, (void **)&unk);
- ok_(__FILE__, line)(hr == expected_hr, "Got hr %#x, expected %#x.\n", hr, expected_hr);
+ ok_(__FILE__, line)(hr == expected_hr, "Got hr %#lx, expected %#lx.\n", hr, expected_hr);
if (SUCCEEDED(hr))
IUnknown_Release(unk);
}
@@ -100,7 +100,7 @@ static void test_interfaces(void)
IPin_Release(pin);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got unexpected refcount %d.\n", ref);
+ ok(!ref, "Got unexpected refcount %ld.\n", ref);
}
static void test_enum_pins(void)
@@ -112,85 +112,85 @@ static void test_enum_pins(void)
HRESULT hr;
ref = get_refcount(filter);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
hr = IBaseFilter_EnumPins(filter, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IBaseFilter_EnumPins(filter, &enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ref = get_refcount(filter);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(enum1);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
hr = IEnumPins_Next(enum1, 1, NULL, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 1, pins, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ref = get_refcount(filter);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(pins[0]);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(enum1);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
IPin_Release(pins[0]);
ref = get_refcount(filter);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
hr = IEnumPins_Next(enum1, 1, pins, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 1, pins, &count);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(count == 1, "Got count %u.\n", count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 1, "Got count %lu.\n", count);
IPin_Release(pins[0]);
hr = IEnumPins_Next(enum1, 1, pins, &count);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
- ok(!count, "Got count %u.\n", count);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
+ ok(!count, "Got count %lu.\n", count);
hr = IEnumPins_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 2, pins, NULL);
- ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 2, pins, &count);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
- ok(count == 1, "Got count %u.\n", count);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
+ ok(count == 1, "Got count %lu.\n", count);
IPin_Release(pins[0]);
hr = IEnumPins_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Clone(enum1, &enum2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Skip(enum1, 2);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Skip(enum1, 1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Skip(enum1, 1);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 1, pins, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum2, 1, pins, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IPin_Release(pins[0]);
IEnumPins_Release(enum2);
IEnumPins_Release(enum1);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static void test_find_pin(void)
@@ -202,22 +202,22 @@ static void test_find_pin(void)
ULONG ref;
hr = IBaseFilter_FindPin(filter, L"input pin", &pin);
- ok(hr == VFW_E_NOT_FOUND, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_FOUND, "Got hr %#lx.\n", hr);
hr = IBaseFilter_EnumPins(filter, &enum_pins);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IBaseFilter_FindPin(filter, L"In", &pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum_pins, 1, &pin2, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(pin2 == pin, "Expected pin %p, got %p.\n", pin, pin2);
IPin_Release(pin2);
IPin_Release(pin);
IEnumPins_Release(enum_pins);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static void test_pin_info(void)
@@ -231,38 +231,38 @@ static void test_pin_info(void)
IPin *pin;
hr = IBaseFilter_FindPin(filter, L"In", &pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ref = get_refcount(filter);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(pin);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
hr = IPin_QueryPinInfo(pin, &info);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter);
ok(info.dir == PINDIR_INPUT, "Got direction %d.\n", info.dir);
ok(!wcscmp(info.achName, L"In"), "Got name %s.\n", wine_dbgstr_w(info.achName));
ref = get_refcount(filter);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(pin);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(dir == PINDIR_INPUT, "Got direction %d.\n", dir);
hr = IPin_QueryId(pin, &id);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(id, L"In"), "Got id %s.\n", wine_dbgstr_w(id));
CoTaskMemFree(id);
hr = IPin_QueryInternalConnections(pin, NULL, NULL);
- ok(hr == E_NOTIMPL, "Got hr %#x.\n", hr);
+ ok(hr == E_NOTIMPL, "Got hr %#lx.\n", hr);
IPin_Release(pin);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static const GUID test_iid = {0x33333333};
@@ -310,53 +310,53 @@ static void test_aggregation(void)
filter = (IBaseFilter *)0xdeadbeef;
hr = CoCreateInstance(&CLSID_NullRenderer, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IBaseFilter, (void **)&filter);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!filter, "Got interface %p.\n", filter);
hr = CoCreateInstance(&CLSID_NullRenderer, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IUnknown, (void **)&unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ok(unk != &test_outer, "Returned IUnknown should not be outer IUnknown.\n");
ref = get_refcount(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
ref = IUnknown_AddRef(unk);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ref = IUnknown_Release(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
hr = IUnknown_QueryInterface(unk, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == unk, "Got unexpected IUnknown %p.\n", unk2);
IUnknown_Release(unk2);
hr = IUnknown_QueryInterface(unk, &IID_IBaseFilter, (void **)&filter);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IBaseFilter_QueryInterface(filter, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
hr = IBaseFilter_QueryInterface(filter, &IID_IBaseFilter, (void **)&filter2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(filter2 == (IBaseFilter *)0xdeadbeef, "Got unexpected IBaseFilter %p.\n", filter2);
hr = IUnknown_QueryInterface(unk, &test_iid, (void **)&unk2);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!unk2, "Got unexpected IUnknown %p.\n", unk2);
hr = IBaseFilter_QueryInterface(filter, &test_iid, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
IBaseFilter_Release(filter);
ref = IUnknown_Release(unk);
- ok(!ref, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(!ref, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
}
static void test_media_types(void)
@@ -371,19 +371,19 @@ static void test_media_types(void)
IBaseFilter_FindPin(filter, L"In", &pin);
hr = IPin_EnumMediaTypes(pin, &enummt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(enummt, 1, &pmt, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
IEnumMediaTypes_Release(enummt);
hr = IPin_QueryAccept(pin, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IPin_Release(pin);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static void test_enum_media_types(void)
@@ -398,36 +398,36 @@ static void test_enum_media_types(void)
IBaseFilter_FindPin(filter, L"In", &pin);
hr = IPin_EnumMediaTypes(pin, &enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(enum1, 1, mts, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(enum1, 1, mts, &count);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
- ok(!count, "Got count %u.\n", count);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
+ ok(!count, "Got count %lu.\n", count);
hr = IEnumMediaTypes_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(enum1, 1, mts, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Clone(enum1, &enum2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Skip(enum1, 1);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(enum2, 1, mts, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
IEnumMediaTypes_Release(enum1);
IEnumMediaTypes_Release(enum2);
IPin_Release(pin);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
struct testfilter
@@ -488,36 +488,36 @@ static void test_allocator(IMemInputPin *input)
HRESULT hr;
hr = IMemInputPin_GetAllocatorRequirements(input, &props);
- ok(hr == E_NOTIMPL, "Got hr %#x.\n", hr);
+ ok(hr == E_NOTIMPL, "Got hr %#lx.\n", hr);
hr = IMemInputPin_GetAllocator(input, &ret_allocator);
- todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == S_OK, "Got hr %#lx.\n", hr);
if (hr == S_OK)
{
hr = IMemAllocator_GetProperties(ret_allocator, &props);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(!props.cBuffers, "Got %d buffers.\n", props.cBuffers);
- ok(!props.cbBuffer, "Got size %d.\n", props.cbBuffer);
- ok(!props.cbAlign, "Got alignment %d.\n", props.cbAlign);
- ok(!props.cbPrefix, "Got prefix %d.\n", props.cbPrefix);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(!props.cBuffers, "Got %ld buffers.\n", props.cBuffers);
+ ok(!props.cbBuffer, "Got size %ld.\n", props.cbBuffer);
+ ok(!props.cbAlign, "Got alignment %ld.\n", props.cbAlign);
+ ok(!props.cbPrefix, "Got prefix %ld.\n", props.cbPrefix);
hr = IMemInputPin_NotifyAllocator(input, ret_allocator, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IMemAllocator_Release(ret_allocator);
}
hr = IMemInputPin_NotifyAllocator(input, NULL, TRUE);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
CoCreateInstance(&CLSID_MemoryAllocator, NULL, CLSCTX_INPROC_SERVER,
&IID_IMemAllocator, (void **)&req_allocator);
hr = IMemInputPin_NotifyAllocator(input, req_allocator, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemInputPin_GetAllocator(input, &ret_allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(ret_allocator == req_allocator, "Allocators didn't match.\n");
IMemAllocator_Release(req_allocator);
@@ -535,9 +535,9 @@ static DWORD WINAPI frame_thread(void *arg)
struct frame_thread_params *params = arg;
HRESULT hr;
- if (winetest_debug > 1) trace("%04x: Sending frame.\n", GetCurrentThreadId());
+ if (winetest_debug > 1) trace("%04lx: Sending frame.\n", GetCurrentThreadId());
hr = IMemInputPin_Receive(params->sink, params->sample);
- if (winetest_debug > 1) trace("%04x: Returned %#x.\n", GetCurrentThreadId(), hr);
+ if (winetest_debug > 1) trace("%04lx: Returned %#lx.\n", GetCurrentThreadId(), hr);
IMediaSample_Release(params->sample);
free(params);
return hr;
@@ -554,22 +554,22 @@ static HANDLE send_frame_time(IMemInputPin *sink, REFERENCE_TIME start_time, uns
BYTE *data;
hr = IMemInputPin_GetAllocator(sink, &allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemAllocator_GetBuffer(allocator, &sample, NULL, NULL, 0);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaSample_GetPointer(sample, &data);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
memset(data, color, 32 * 16 * 2);
hr = IMediaSample_SetActualDataLength(sample, 32 * 16 * 2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
start_time *= 10000000;
end_time = start_time + 10000000;
hr = IMediaSample_SetTime(sample, &start_time, &end_time);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
params->sink = sink;
params->sample = sample;
@@ -607,132 +607,132 @@ static void test_filter_state(IMemInputPin *input, IFilterGraph2 *graph)
thread = send_frame(input);
hr = join_thread(thread);
- todo_wine ok(hr == E_FAIL, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == E_FAIL, "Got hr %#lx.\n", hr);
/* The renderer is not fully paused until it receives a sample. The thread
* sending the sample blocks in IMemInputPin_Receive() until the filter is
* stopped or run. */
hr = IMediaControl_Pause(control);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#x.\n", hr);
+ ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#lx.\n", hr);
thread = send_frame(input);
hr = IMediaControl_GetState(control, 1000, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(WaitForSingleObject(thread, 100) == WAIT_TIMEOUT, "Thread should block in Receive().\n");
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = join_thread(thread);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
/* The sink will decommit our allocator for us when stopping, and recommit
* it when pausing. */
hr = IMemInputPin_GetAllocator(input, &allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemAllocator_GetBuffer(allocator, &sample, NULL, NULL, 0);
- todo_wine ok(hr == VFW_E_NOT_COMMITTED, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == VFW_E_NOT_COMMITTED, "Got hr %#lx.\n", hr);
if (hr == S_OK) IMediaSample_Release(sample);
hr = IMemAllocator_Commit(allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
thread = send_frame(input);
hr = join_thread(thread);
- todo_wine ok(hr == E_FAIL, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == E_FAIL, "Got hr %#lx.\n", hr);
hr = IMediaControl_Pause(control);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#x.\n", hr);
+ ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#lx.\n", hr);
thread = send_frame(input);
hr = IMediaControl_GetState(control, 1000, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(WaitForSingleObject(thread, 100) == WAIT_TIMEOUT, "Thread should block in Receive().\n");
hr = IMediaControl_Run(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = join_thread(thread);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
thread = send_frame(input);
hr = join_thread(thread);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_Pause(control);
- todo_wine ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#lx.\n", hr);
thread = send_frame(input);
hr = IMediaControl_GetState(control, 1000, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(WaitForSingleObject(thread, 100) == WAIT_TIMEOUT, "Thread should block in Receive().\n");
hr = IMediaControl_Run(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = join_thread(thread);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_Pause(control);
- todo_wine ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#x.\n", hr);
- ok(state == State_Paused, "Got state %u.\n", state);
+ todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#lx.\n", hr);
+ ok(state == State_Paused, "Got state %lu.\n", state);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_Pause(control);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#x.\n", hr);
- ok(state == State_Paused, "Got state %u.\n", state);
+ ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#lx.\n", hr);
+ ok(state == State_Paused, "Got state %lu.\n", state);
hr = IMediaControl_Run(control);
- todo_wine ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#x.\n", hr);
- ok(state == State_Running, "Got state %u.\n", state);
+ todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#lx.\n", hr);
+ ok(state == State_Running, "Got state %lu.\n", state);
thread = send_frame(input);
hr = join_thread(thread);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IMemAllocator_Release(allocator);
IMediaControl_Release(control);
@@ -748,54 +748,54 @@ static void test_flushing(IPin *pin, IMemInputPin *input, IFilterGraph2 *graph)
IFilterGraph2_QueryInterface(graph, &IID_IMediaControl, (void **)&control);
hr = IMediaControl_Pause(control);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
thread = send_frame(input);
ok(WaitForSingleObject(thread, 100) == WAIT_TIMEOUT, "Thread should block in Receive().\n");
hr = IMediaControl_GetState(control, 0, &state);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_BeginFlush(pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = join_thread(thread);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
thread = send_frame(input);
hr = join_thread(thread);
- todo_wine ok(hr == E_FAIL, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == E_FAIL, "Got hr %#lx.\n", hr);
hr = IPin_EndFlush(pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
/* We dropped the sample we were holding, so now we need a new one... */
hr = IMediaControl_GetState(control, 0, &state);
- todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == VFW_S_STATE_INTERMEDIATE, "Got hr %#lx.\n", hr);
thread = send_frame(input);
ok(WaitForSingleObject(thread, 100) == WAIT_TIMEOUT, "Thread should block in Receive().\n");
hr = IMediaControl_Run(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = join_thread(thread);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_BeginFlush(pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = join_thread(send_frame(input));
- todo_wine ok(hr == E_FAIL, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == E_FAIL, "Got hr %#lx.\n", hr);
hr = IPin_EndFlush(pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = join_thread(send_frame(input));
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IMediaControl_Release(control);
}
@@ -811,14 +811,14 @@ static unsigned int check_event_code(IMediaEvent *eventsrc, DWORD timeout, LONG
{
if (code == expected_code)
{
- ok(param1 == expected1, "Got param1 %#lx.\n", param1);
- ok(param2 == expected2, "Got param2 %#lx.\n", param2);
+ ok(param1 == expected1, "Got param1 %#Ix.\n", param1);
+ ok(param2 == expected2, "Got param2 %#Ix.\n", param2);
ret++;
}
IMediaEvent_FreeEventParams(eventsrc, code, param1, param2);
timeout = 0;
}
- ok(hr == E_ABORT, "Got hr %#x.\n", hr);
+ ok(hr == E_ABORT, "Got hr %#lx.\n", hr);
return ret;
}
@@ -860,81 +860,81 @@ static void test_connect_pin(void)
peer = (IPin *)0xdeadbeef;
hr = IPin_ConnectedTo(pin, &peer);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
ok(!peer, "Got peer %p.\n", peer);
hr = IPin_ConnectionMediaType(pin, &mt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_ConnectDirect(graph, &source.source.pin.IPin_iface, pin, &req_mt);
- ok(hr == VFW_E_NOT_STOPPED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_STOPPED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_ConnectDirect(graph, &source.source.pin.IPin_iface, pin, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_ConnectedTo(pin, &peer);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(peer == &source.source.pin.IPin_iface, "Got peer %p.\n", peer);
IPin_Release(peer);
hr = IPin_ConnectionMediaType(pin, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!memcmp(&mt, &req_mt, sizeof(AM_MEDIA_TYPE)), "Media types didn't match.\n");
hr = IMediaControl_Pause(control);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_Disconnect(graph, pin);
- ok(hr == VFW_E_NOT_STOPPED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_STOPPED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IPin_QueryInterface(pin, &IID_IMemInputPin, (void **)&input);
test_allocator(input);
hr = IMemInputPin_GetAllocator(input, &allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemAllocator_SetProperties(allocator, &req_props, &ret_props);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!memcmp(&ret_props, &req_props, sizeof(req_props)), "Properties did not match.\n");
hr = IMemAllocator_Commit(allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IMemAllocator_Release(allocator);
hr = IMemInputPin_ReceiveCanBlock(input);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
test_filter_state(input, graph);
test_flushing(pin, input, graph);
hr = IFilterGraph2_Disconnect(graph, pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_Disconnect(graph, pin);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
ok(source.source.pin.peer == pin, "Got peer %p.\n", peer);
IFilterGraph2_Disconnect(graph, &source.source.pin.IPin_iface);
peer = (IPin *)0xdeadbeef;
hr = IPin_ConnectedTo(pin, &peer);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
ok(!peer, "Got peer %p.\n", peer);
hr = IPin_ConnectionMediaType(pin, &mt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
IMemInputPin_Release(input);
IPin_Release(pin);
IMediaControl_Release(control);
ref = IFilterGraph2_Release(graph);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ref = IBaseFilter_Release(&source.filter.IBaseFilter_iface);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static void test_unconnected_eos(void)
@@ -948,49 +948,49 @@ static void test_unconnected_eos(void)
ULONG ref;
hr = IFilterGraph2_AddFilter(graph, filter, L"renderer");
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_QueryInterface(graph, &IID_IMediaControl, (void **)&control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_QueryInterface(graph, &IID_IMediaEvent, (void **)&eventsrc);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ret = check_ec_complete(eventsrc, 0);
ok(!ret, "Got %u EC_COMPLETE events.\n", ret);
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ret = check_ec_complete(eventsrc, 0);
ok(!ret, "Got %u EC_COMPLETE events.\n", ret);
hr = IMediaControl_Run(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ret = check_ec_complete(eventsrc, 0);
ok(ret == 1, "Got %u EC_COMPLETE events.\n", ret);
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ret = check_ec_complete(eventsrc, 0);
ok(!ret, "Got %u EC_COMPLETE events.\n", ret);
hr = IMediaControl_Run(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ret = check_ec_complete(eventsrc, 0);
ok(ret == 1, "Got %u EC_COMPLETE events.\n", ret);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ret = check_ec_complete(eventsrc, 0);
ok(!ret, "Got %u EC_COMPLETE events.\n", ret);
hr = IMediaControl_Run(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ret = check_ec_complete(eventsrc, 0);
ok(ret == 1, "Got %u EC_COMPLETE events.\n", ret);
@@ -998,9 +998,9 @@ static void test_unconnected_eos(void)
IMediaControl_Release(control);
IMediaEvent_Release(eventsrc);
ref = IFilterGraph2_Release(graph);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
START_TEST(nullrenderer)
@@ -1014,7 +1014,7 @@ START_TEST(nullrenderer)
&IID_IBaseFilter, (void **)&filter)))
{
/* qedit.dll does not exist on 2003. */
- win_skip("Failed to create null renderer filter, hr %#x.\n", hr);
+ win_skip("Failed to create null renderer filter, hr %#lx.\n", hr);
return;
}
IBaseFilter_Release(filter);
diff --git a/dlls/qedit/tests/samplegrabber.c b/dlls/qedit/tests/samplegrabber.c
index 13ec04cdc1c..32fcfc1eb2b 100644
--- a/dlls/qedit/tests/samplegrabber.c
+++ b/dlls/qedit/tests/samplegrabber.c
@@ -29,7 +29,7 @@ static IBaseFilter *create_sample_grabber(void)
IBaseFilter *filter = NULL;
HRESULT hr = CoCreateInstance(&CLSID_SampleGrabber, NULL, CLSCTX_INPROC_SERVER,
&IID_IBaseFilter, (void **)&filter);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
return filter;
}
@@ -59,13 +59,13 @@ static void check_interface_(unsigned int line, void *iface_ptr, REFIID iid, BOO
expect_ref = get_refcount(iface);
hr = IUnknown_QueryInterface(iface, iid, (void **)&unk);
- ok_(__FILE__, line)(hr == expected_hr, "Got hr %#x, expected %#x.\n", hr, expected_hr);
+ ok_(__FILE__, line)(hr == expected_hr, "Got hr %#lx, expected %#lx.\n", hr, expected_hr);
if (SUCCEEDED(hr))
{
ref = get_refcount(iface);
- ok_(__FILE__, line)(ref == expect_ref + 1, "Expected %u references, got %u.\n", expect_ref + 1, ref);
+ ok_(__FILE__, line)(ref == expect_ref + 1, "Expected %lu references, got %lu.\n", expect_ref + 1, ref);
ref = get_refcount(unk);
- ok_(__FILE__, line)(ref == expect_ref + 1, "Expected %u references, got %u.\n", expect_ref + 1, ref);
+ ok_(__FILE__, line)(ref == expect_ref + 1, "Expected %lu references, got %lu.\n", expect_ref + 1, ref);
IUnknown_Release(unk);
}
}
@@ -117,10 +117,10 @@ static void test_interfaces(void)
/* Queries for IMediaPosition or IMediaSeeking do not seem to increase the
* reference count. */
hr = IPin_QueryInterface(pin, &IID_IMediaPosition, (void **)&unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IUnknown_Release(unk);
hr = IPin_QueryInterface(pin, &IID_IMediaSeeking, (void **)&unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IUnknown_Release(unk);
check_interface(pin, &IID_IPin, TRUE);
todo_wine check_interface(pin, &IID_IQualityControl, TRUE);
@@ -133,7 +133,7 @@ static void test_interfaces(void)
IPin_Release(pin);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got unexpected refcount %d.\n", ref);
+ ok(!ref, "Got unexpected refcount %ld.\n", ref);
}
static void test_enum_pins(void)
@@ -145,116 +145,116 @@ static void test_enum_pins(void)
HRESULT hr;
ref = get_refcount(filter);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
hr = IBaseFilter_EnumPins(filter, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IBaseFilter_EnumPins(filter, &enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ref = get_refcount(filter);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(enum1);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
hr = IEnumPins_Next(enum1, 1, NULL, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 1, pins, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ref = get_refcount(filter);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(pins[0]);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(enum1);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
IPin_Release(pins[0]);
ref = get_refcount(filter);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
hr = IEnumPins_Next(enum1, 1, pins, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ref = get_refcount(filter);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(pins[0]);
- ok(ref == 3, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 3, "Got unexpected refcount %ld.\n", ref);
ref = get_refcount(enum1);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
IPin_Release(pins[0]);
ref = get_refcount(filter);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
hr = IEnumPins_Next(enum1, 1, pins, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 1, pins, &count);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(count == 1, "Got count %u.\n", count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 1, "Got count %lu.\n", count);
IPin_Release(pins[0]);
hr = IEnumPins_Next(enum1, 1, pins, &count);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(count == 1, "Got count %u.\n", count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 1, "Got count %lu.\n", count);
IPin_Release(pins[0]);
hr = IEnumPins_Next(enum1, 1, pins, &count);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
- ok(!count, "Got count %u.\n", count);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
+ ok(!count, "Got count %lu.\n", count);
hr = IEnumPins_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 2, pins, NULL);
- ok(hr == E_INVALIDARG, "Got hr %#x.\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 2, pins, &count);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(count == 2, "Got count %u.\n", count);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(count == 2, "Got count %lu.\n", count);
IPin_Release(pins[0]);
IPin_Release(pins[1]);
hr = IEnumPins_Next(enum1, 2, pins, &count);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
- ok(!count, "Got count %u.\n", count);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
+ ok(!count, "Got count %lu.\n", count);
hr = IEnumPins_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 3, pins, &count);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
- ok(count == 2, "Got count %u.\n", count);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
+ ok(count == 2, "Got count %lu.\n", count);
IPin_Release(pins[0]);
IPin_Release(pins[1]);
hr = IEnumPins_Reset(enum1);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Clone(enum1, &enum2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Skip(enum1, 3);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Skip(enum1, 2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Skip(enum1, 1);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum1, 1, pins, NULL);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum2, 1, pins, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IPin_Release(pins[0]);
IEnumPins_Release(enum2);
IEnumPins_Release(enum1);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static void test_find_pin(void)
@@ -266,32 +266,32 @@ static void test_find_pin(void)
ULONG ref;
hr = IBaseFilter_FindPin(filter, L"Input", &pin);
- ok(hr == VFW_E_NOT_FOUND, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_FOUND, "Got hr %#lx.\n", hr);
hr = IBaseFilter_FindPin(filter, L"Output", &pin);
- ok(hr == VFW_E_NOT_FOUND, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_FOUND, "Got hr %#lx.\n", hr);
hr = IBaseFilter_EnumPins(filter, &enum_pins);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IBaseFilter_FindPin(filter, L"In", &pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum_pins, 1, &pin2, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(pin2 == pin, "Expected pin %p, got %p.\n", pin, pin2);
IPin_Release(pin2);
IPin_Release(pin);
hr = IBaseFilter_FindPin(filter, L"Out", &pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumPins_Next(enum_pins, 1, &pin2, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(pin2 == pin, "Expected pin %p, got %p.\n", pin, pin2);
IPin_Release(pin2);
IPin_Release(pin);
IEnumPins_Release(enum_pins);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static void test_pin_info(void)
@@ -306,55 +306,55 @@ static void test_pin_info(void)
IPin *pin;
hr = IBaseFilter_FindPin(filter, L"In", &pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryPinInfo(pin, &info);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter);
ok(info.dir == PINDIR_INPUT, "Got direction %d.\n", info.dir);
todo_wine ok(!wcscmp(info.achName, L"Input"), "Got name %s.\n", wine_dbgstr_w(info.achName));
IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(dir == PINDIR_INPUT, "Got direction %d.\n", dir);
hr = IPin_QueryId(pin, &id);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(id, L"In"), "Got id %s.\n", wine_dbgstr_w(id));
CoTaskMemFree(id);
hr = IPin_QueryInternalConnections(pin, NULL, &count);
- ok(hr == E_NOTIMPL, "Got hr %#x.\n", hr);
+ ok(hr == E_NOTIMPL, "Got hr %#lx.\n", hr);
IPin_Release(pin);
hr = IBaseFilter_FindPin(filter, L"Out", &pin);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryPinInfo(pin, &info);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(info.pFilter == filter, "Expected filter %p, got %p.\n", filter, info.pFilter);
ok(info.dir == PINDIR_OUTPUT, "Got direction %d.\n", info.dir);
todo_wine ok(!wcscmp(info.achName, L"Output"), "Got name %s.\n", wine_dbgstr_w(info.achName));
IBaseFilter_Release(info.pFilter);
hr = IPin_QueryDirection(pin, &dir);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(dir == PINDIR_OUTPUT, "Got direction %d.\n", dir);
hr = IPin_QueryId(pin, &id);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!wcscmp(id, L"Out"), "Got id %s.\n", wine_dbgstr_w(id));
CoTaskMemFree(id);
hr = IPin_QueryInternalConnections(pin, NULL, &count);
- ok(hr == E_NOTIMPL, "Got hr %#x.\n", hr);
+ ok(hr == E_NOTIMPL, "Got hr %#lx.\n", hr);
IPin_Release(pin);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
static const GUID test_iid = {0x33333333};
@@ -402,53 +402,53 @@ static void test_aggregation(void)
filter = (IBaseFilter *)0xdeadbeef;
hr = CoCreateInstance(&CLSID_SampleGrabber, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IBaseFilter, (void **)&filter);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!filter, "Got interface %p.\n", filter);
hr = CoCreateInstance(&CLSID_SampleGrabber, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IUnknown, (void **)&unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ok(unk != &test_outer, "Returned IUnknown should not be outer IUnknown.\n");
ref = get_refcount(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
ref = IUnknown_AddRef(unk);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ref = IUnknown_Release(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
hr = IUnknown_QueryInterface(unk, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == unk, "Got unexpected IUnknown %p.\n", unk2);
IUnknown_Release(unk2);
hr = IUnknown_QueryInterface(unk, &IID_IBaseFilter, (void **)&filter);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IBaseFilter_QueryInterface(filter, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
hr = IBaseFilter_QueryInterface(filter, &IID_IBaseFilter, (void **)&filter2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(filter2 == (IBaseFilter *)0xdeadbeef, "Got unexpected IBaseFilter %p.\n", filter2);
hr = IUnknown_QueryInterface(unk, &test_iid, (void **)&unk2);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!unk2, "Got unexpected IUnknown %p.\n", unk2);
hr = IBaseFilter_QueryInterface(filter, &test_iid, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
IBaseFilter_Release(filter);
ref = IUnknown_Release(unk);
- ok(!ref, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(!ref, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
}
static void test_media_types(void)
@@ -482,94 +482,94 @@ static void test_media_types(void)
IBaseFilter_FindPin(filter, L"Out", &source);
hr = IPin_EnumMediaTypes(sink, &enummt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
hr = IPin_EnumMediaTypes(source, &enummt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = ISampleGrabber_SetMediaType(grabber, &match_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_EnumMediaTypes(sink, &enummt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
hr = IPin_EnumMediaTypes(source, &enummt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
match_mt.majortype = MEDIATYPE_Video;
match_mt.subtype = GUID_NULL;
hr = ISampleGrabber_SetMediaType(grabber, &match_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
mt.majortype = GUID_NULL;
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
mt.majortype = match_mt.majortype;
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
match_mt.subtype = MEDIASUBTYPE_RGB8;
match_mt.formattype = GUID_NULL;
hr = ISampleGrabber_SetMediaType(grabber, &match_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
mt.subtype = GUID_NULL;
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
mt.subtype = match_mt.subtype;
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
match_mt.formattype = FORMAT_None;
hr = ISampleGrabber_SetMediaType(grabber, &match_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
mt.formattype = GUID_NULL;
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
mt.formattype = match_mt.formattype;
hr = IPin_QueryAccept(sink, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IPin_Release(sink);
IPin_Release(source);
ISampleGrabber_Release(grabber);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
struct testfilter
@@ -637,18 +637,18 @@ static void test_sink_allocator(IPin *pin)
IPin_QueryInterface(pin, &IID_IMemInputPin, (void **)&input);
hr = IMemInputPin_NotifyAllocator(input, NULL, TRUE);
- todo_wine ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IMemInputPin_GetAllocatorRequirements(input, &ret_props);
- ok(hr == E_NOTIMPL, "Got hr %#x.\n", hr);
+ ok(hr == E_NOTIMPL, "Got hr %#lx.\n", hr);
hr = IMemInputPin_GetAllocator(input, &ret_allocator);
- todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == S_OK, "Got hr %#lx.\n", hr);
if (hr == S_OK)
{
hr = IMemInputPin_NotifyAllocator(input, ret_allocator, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IMemAllocator_Release(ret_allocator);
}
@@ -656,15 +656,15 @@ static void test_sink_allocator(IPin *pin)
&IID_IMemAllocator, (void **)&req_allocator);
hr = IMemInputPin_NotifyAllocator(input, req_allocator, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemInputPin_GetAllocator(input, &ret_allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(ret_allocator == req_allocator, "Allocators didn't match.\n");
IMemAllocator_Release(ret_allocator);
hr = IMemAllocator_SetProperties(req_allocator, &req_props, &ret_props);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IMemAllocator_Release(req_allocator);
IMemInputPin_Release(input);
@@ -681,7 +681,7 @@ static HRESULT WINAPI testsource_AttemptConnection(struct strmbase_source *iface
if (FAILED(hr = IPin_ReceiveConnection(peer, &iface->pin.IPin_iface, mt)))
{
- ok(hr == VFW_E_TYPE_NOT_ACCEPTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_TYPE_NOT_ACCEPTED, "Got hr %#lx.\n", hr);
IPin_Release(peer);
iface->pin.peer = NULL;
FreeMediaType(&iface->pin.mt);
@@ -740,32 +740,32 @@ static HRESULT WINAPI testsink_Receive(struct strmbase_sink *iface, IMediaSample
HRESULT hr;
size = IMediaSample_GetSize(sample);
- ok(size == 256, "Got size %u.\n", size);
+ ok(size == 256, "Got size %lu.\n", size);
size = IMediaSample_GetActualDataLength(sample);
- ok(size == 200, "Got valid size %u.\n", size);
+ ok(size == 200, "Got valid size %lu.\n", size);
hr = IMediaSample_GetPointer(sample, &data);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
for (i = 0; i < size; ++i)
expect[i] = i;
ok(!memcmp(data, expect, size), "Data didn't match.\n");
hr = IMediaSample_GetTime(sample, &start, &stop);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(start == 30000, "Got start time %s.\n", wine_dbgstr_longlong(start));
ok(stop == 40000, "Got stop time %s.\n", wine_dbgstr_longlong(stop));
hr = IMediaSample_GetMediaTime(sample, &start, &stop);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(start == 10000, "Got start time %s.\n", wine_dbgstr_longlong(start));
ok(stop == 20000, "Got stop time %s.\n", wine_dbgstr_longlong(stop));
hr = IMediaSample_IsDiscontinuity(sample);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaSample_IsPreroll(sample);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
hr = IMediaSample_IsSyncPoint(sample);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
++filter->got_sample;
@@ -835,58 +835,58 @@ static void test_sample_processing(IMediaControl *control, IMemInputPin *input,
BYTE *data;
hr = IMemInputPin_ReceiveCanBlock(input);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemInputPin_GetAllocator(input, &allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemAllocator_GetBuffer(allocator, &sample, NULL, NULL, 0);
- ok(hr == VFW_E_NOT_COMMITTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_COMMITTED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemAllocator_GetBuffer(allocator, &sample, NULL, NULL, 0);
- todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == S_OK, "Got hr %#lx.\n", hr);
if (hr != S_OK)
{
IMemAllocator_Commit(allocator);
hr = IMemAllocator_GetBuffer(allocator, &sample, NULL, NULL, 0);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
}
hr = IMediaSample_GetPointer(sample, &data);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
size = IMediaSample_GetSize(sample);
- ok(size == 256, "Got size %d.\n", size);
+ ok(size == 256, "Got size %ld.\n", size);
for (i = 0; i < 200; ++i)
data[i] = i;
hr = IMediaSample_SetActualDataLength(sample, 200);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
start = 10000;
stop = 20000;
hr = IMediaSample_SetMediaTime(sample, &start, &stop);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
start = 30000;
stop = 40000;
hr = IMediaSample_SetTime(sample, &start, &stop);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaSample_SetDiscontinuity(sample, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaSample_SetSyncPoint(sample, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemInputPin_Receive(input, sample);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(sink->got_sample == 1, "Got %u calls to Receive().\n", sink->got_sample);
sink->got_sample = 0;
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemInputPin_Receive(input, sample);
- todo_wine ok(hr == VFW_E_WRONG_STATE, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == VFW_E_WRONG_STATE, "Got hr %#lx.\n", hr);
IMediaSample_Release(sample);
IMemAllocator_Release(allocator);
@@ -903,80 +903,80 @@ static void test_streaming_events(IMediaControl *control, IPin *sink,
LONG i;
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemInputPin_GetAllocator(input, &allocator);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMemAllocator_GetBuffer(allocator, &sample, NULL, NULL, 0);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaSample_GetPointer(sample, &data);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
for (i = 0; i < 200; ++i)
data[i] = i;
hr = IMediaSample_SetActualDataLength(sample, 200);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
start = 10000;
stop = 20000;
hr = IMediaSample_SetMediaTime(sample, &start, &stop);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
start = 30000;
stop = 40000;
hr = IMediaSample_SetTime(sample, &start, &stop);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaSample_SetDiscontinuity(sample, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IMediaSample_SetSyncPoint(sample, TRUE);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(!testsink->got_new_segment, "Got %u calls to IPin::NewSegment().\n", testsink->got_new_segment);
hr = IPin_NewSegment(sink, 10000, 20000, 1.0);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(testsink->got_new_segment == 1, "Got %u calls to IPin::NewSegment().\n", testsink->got_new_segment);
ok(!testsink->got_eos, "Got %u calls to IPin::EndOfStream().\n", testsink->got_eos);
hr = IPin_EndOfStream(sink);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
todo_wine ok(!testsink->got_sample, "Got %u calls to Receive().\n", testsink->got_sample);
ok(testsink->got_eos == 1, "Got %u calls to IPin::EndOfStream().\n", testsink->got_eos);
testsink->got_eos = 0;
hr = IPin_EndOfStream(sink);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(testsink->got_eos == 1, "Got %u calls to IPin::EndOfStream().\n", testsink->got_eos);
testsink->got_eos = 0;
hr = IMemInputPin_Receive(input, sample);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
todo_wine ok(testsink->got_sample == 1, "Got %u calls to Receive().\n", testsink->got_sample);
testsink->got_sample = 0;
ok(!testsink->got_begin_flush, "Got %u calls to IPin::BeginFlush().\n", testsink->got_begin_flush);
hr = IPin_BeginFlush(sink);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(testsink->got_begin_flush == 1, "Got %u calls to IPin::BeginFlush().\n", testsink->got_begin_flush);
hr = IMemInputPin_Receive(input, sample);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(testsink->got_sample == 1, "Got %u calls to Receive().\n", testsink->got_sample);
testsink->got_sample = 0;
hr = IPin_EndOfStream(sink);
- todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr);
+ todo_wine ok(hr == S_OK, "Got hr %#lx.\n", hr);
todo_wine ok(testsink->got_eos == 1, "Got %u calls to IPin::EndOfStream().\n", testsink->got_eos);
testsink->got_eos = 0;
ok(!testsink->got_end_flush, "Got %u calls to IPin::EndFlush().\n", testsink->got_end_flush);
hr = IPin_EndFlush(sink);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(testsink->got_end_flush == 1, "Got %u calls to IPin::EndFlush().\n", testsink->got_end_flush);
hr = IMemInputPin_Receive(input, sample);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(testsink->got_sample == 1, "Got %u calls to Receive().\n", testsink->got_sample);
testsink->got_sample = 0;
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
IMediaSample_Release(sample);
IMemAllocator_Release(allocator);
}
@@ -1019,57 +1019,57 @@ static void test_connect_pin(void)
testsource.source_mt.formattype = FORMAT_VideoInfo;
hr = ISampleGrabber_GetConnectedMediaType(grabber, &mt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
/* Test sink connection. */
peer = (IPin *)0xdeadbeef;
hr = IPin_ConnectedTo(sink, &peer);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
ok(!peer, "Got peer %p.\n", peer);
hr = IPin_ConnectionMediaType(sink, &mt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_ConnectDirect(graph, &testsource.source.pin.IPin_iface, sink, &req_mt);
- ok(hr == VFW_E_NOT_STOPPED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_STOPPED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_ConnectDirect(graph, &testsource.source.pin.IPin_iface, sink, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_ConnectedTo(sink, &peer);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(peer == &testsource.source.pin.IPin_iface, "Got peer %p.\n", peer);
IPin_Release(peer);
hr = IPin_ConnectionMediaType(sink, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&mt, &req_mt), "Media types didn't match.\n");
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_Disconnect(graph, sink);
- ok(hr == VFW_E_NOT_STOPPED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_STOPPED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = ISampleGrabber_GetConnectedMediaType(grabber, NULL);
- ok(hr == E_POINTER, "Got hr %#x.\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = ISampleGrabber_GetConnectedMediaType(grabber, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&mt, &req_mt), "Media types didn't match.\n");
hr = IPin_EnumMediaTypes(sink, &enummt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
hr = IPin_EnumMediaTypes(source, &enummt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(enummt, 1, &pmt, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(pmt, &testsource.source_mt), "Media types didn't match.\n");
IEnumMediaTypes_Release(enummt);
@@ -1077,68 +1077,68 @@ static void test_connect_pin(void)
req_mt.subtype = MEDIASUBTYPE_RGB8;
req_mt.formattype = FORMAT_VideoInfo;
hr = IPin_QueryAccept(sink, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &req_mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
req_mt.bTemporalCompression = TRUE;
hr = IPin_QueryAccept(source, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
memset(&mt, 0, sizeof(AM_MEDIA_TYPE));
mt.majortype = MEDIATYPE_Midi;
hr = ISampleGrabber_SetMediaType(grabber, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_QueryAccept(source, &req_mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
req_mt.majortype = MEDIATYPE_Midi;
req_mt.bTemporalCompression = FALSE;
hr = IPin_QueryAccept(source, &req_mt);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
req_mt.bTemporalCompression = TRUE;
hr = IPin_QueryAccept(source, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
memset(&mt, 0, sizeof(AM_MEDIA_TYPE));
hr = ISampleGrabber_SetMediaType(grabber, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
/* Test source connection. */
peer = (IPin *)0xdeadbeef;
hr = IPin_ConnectedTo(source, &peer);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
ok(!peer, "Got peer %p.\n", peer);
hr = IPin_ConnectionMediaType(source, &mt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
/* Exact connection. */
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NOT_STOPPED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_STOPPED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
req_mt.bTemporalCompression = FALSE;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_TYPE_NOT_ACCEPTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_TYPE_NOT_ACCEPTED, "Got hr %#lx.\n", hr);
req_mt.bTemporalCompression = TRUE;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IPin_ConnectedTo(source, &peer);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(peer == &testsink.sink.pin.IPin_iface, "Got peer %p.\n", peer);
IPin_Release(peer);
hr = IPin_ConnectionMediaType(source, &mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&mt, &req_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsink.sink.pin.mt, &req_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
@@ -1147,27 +1147,27 @@ static void test_connect_pin(void)
test_streaming_events(control, sink, input, &testsink);
hr = IMediaControl_Pause(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_Disconnect(graph, source);
- ok(hr == VFW_E_NOT_STOPPED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_STOPPED, "Got hr %#lx.\n", hr);
hr = IMediaControl_Stop(control);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_Disconnect(graph, source);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_Disconnect(graph, source);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
ok(testsink.sink.pin.peer == source, "Got peer %p.\n", testsink.sink.pin.peer);
IFilterGraph2_Disconnect(graph, &testsink.sink.pin.IPin_iface);
/* Connection with wildcards. */
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, NULL);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
testsource.source_mt.bTemporalCompression = TRUE;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&testsink.sink.pin.mt, &testsource.source_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
IFilterGraph2_Disconnect(graph, source);
@@ -1176,7 +1176,7 @@ static void test_connect_pin(void)
req_mt.majortype = GUID_NULL;
req_mt.bTemporalCompression = FALSE;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&testsink.sink.pin.mt, &testsource.source_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
IFilterGraph2_Disconnect(graph, source);
@@ -1184,11 +1184,11 @@ static void test_connect_pin(void)
req_mt.subtype = MEDIASUBTYPE_RGB32;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
req_mt.subtype = GUID_NULL;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&testsink.sink.pin.mt, &testsource.source_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
IFilterGraph2_Disconnect(graph, source);
@@ -1196,13 +1196,13 @@ static void test_connect_pin(void)
req_mt.formattype = FORMAT_None;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
req_mt.majortype = MEDIATYPE_Video;
req_mt.subtype = MEDIASUBTYPE_RGB8;
req_mt.formattype = GUID_NULL;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&testsink.sink.pin.mt, &testsource.source_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
IFilterGraph2_Disconnect(graph, source);
@@ -1210,11 +1210,11 @@ static void test_connect_pin(void)
req_mt.subtype = MEDIASUBTYPE_RGB32;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
req_mt.subtype = GUID_NULL;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&testsink.sink.pin.mt, &testsource.source_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
IFilterGraph2_Disconnect(graph, source);
@@ -1222,12 +1222,12 @@ static void test_connect_pin(void)
req_mt.majortype = MEDIATYPE_Audio;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
testsource.source_mt.majortype = testsource.source_mt.subtype = testsource.source_mt.formattype = GUID_NULL;
req_mt.majortype = req_mt.subtype = req_mt.formattype = GUID_NULL;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&testsink.sink.pin.mt, &testsource.source_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
IFilterGraph2_Disconnect(graph, source);
@@ -1235,17 +1235,17 @@ static void test_connect_pin(void)
req_mt.majortype = MEDIATYPE_Video;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
req_mt.majortype = GUID_NULL;
req_mt.subtype = MEDIASUBTYPE_RGB8;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
req_mt.subtype = GUID_NULL;
req_mt.formattype = FORMAT_None;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, &req_mt);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
req_mt.formattype = GUID_NULL;
/* Test enumeration of sink media types. */
@@ -1253,20 +1253,20 @@ static void test_connect_pin(void)
testsink.sink_mt = &req_mt;
req_mt.majortype = MEDIATYPE_Audio;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, NULL);
- ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NO_ACCEPTABLE_TYPES, "Got hr %#lx.\n", hr);
req_mt.majortype = GUID_NULL;
req_mt.bTemporalCompression = TRUE;
req_mt.lSampleSize = 444;
hr = IFilterGraph2_ConnectDirect(graph, source, &testsink.sink.pin.IPin_iface, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(&testsink.sink.pin.mt, &req_mt), "Media types didn't match.\n");
ok(compare_media_types(&testsource.source.pin.mt, &testsink.sink.pin.mt), "Media types didn't match.\n");
hr = IPin_EnumMediaTypes(sink, &enummt);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IEnumMediaTypes_Next(enummt, 1, &pmt, NULL);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(compare_media_types(pmt, testsink.sink_mt), "Media types didn't match.\n");
IEnumMediaTypes_Release(enummt);
@@ -1274,33 +1274,33 @@ static void test_connect_pin(void)
IFilterGraph2_Disconnect(graph, &testsink.sink.pin.IPin_iface);
hr = IFilterGraph2_Disconnect(graph, sink);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IFilterGraph2_Disconnect(graph, sink);
- ok(hr == S_FALSE, "Got hr %#x.\n", hr);
+ ok(hr == S_FALSE, "Got hr %#lx.\n", hr);
ok(testsource.source.pin.peer == sink, "Got peer %p.\n", testsource.source.pin.peer);
IFilterGraph2_Disconnect(graph, &testsource.source.pin.IPin_iface);
peer = (IPin *)0xdeadbeef;
hr = IPin_ConnectedTo(sink, &peer);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
ok(!peer, "Got peer %p.\n", peer);
hr = IPin_ConnectionMediaType(sink, &mt);
- ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#x.\n", hr);
+ ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
IMemInputPin_Release(input);
IPin_Release(sink);
IPin_Release(source);
IMediaControl_Release(control);
ref = IFilterGraph2_Release(graph);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ISampleGrabber_Release(grabber);
ref = IBaseFilter_Release(filter);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ref = IBaseFilter_Release(&testsource.filter.IBaseFilter_iface);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
ref = IBaseFilter_Release(&testsink.filter.IBaseFilter_iface);
- ok(!ref, "Got outstanding refcount %d.\n", ref);
+ ok(!ref, "Got outstanding refcount %ld.\n", ref);
}
START_TEST(samplegrabber)
@@ -1314,7 +1314,7 @@ START_TEST(samplegrabber)
&IID_IBaseFilter, (void **)&filter)))
{
/* qedit.dll does not exist on 2003. */
- win_skip("Failed to create sample grabber filter, hr %#x.\n", hr);
+ win_skip("Failed to create sample grabber filter, hr %#lx.\n", hr);
return;
}
IBaseFilter_Release(filter);
diff --git a/dlls/qedit/tests/timeline.c b/dlls/qedit/tests/timeline.c
index 0d01d519fd9..336efafff91 100644
--- a/dlls/qedit/tests/timeline.c
+++ b/dlls/qedit/tests/timeline.c
@@ -74,53 +74,53 @@ static void test_aggregation(void)
timeline = (IAMTimeline *)0xdeadbeef;
hr = CoCreateInstance(&CLSID_AMTimeline, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IAMTimeline, (void **)&timeline);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!timeline, "Got interface %p.\n", timeline);
hr = CoCreateInstance(&CLSID_AMTimeline, &test_outer, CLSCTX_INPROC_SERVER,
&IID_IUnknown, (void **)&unk);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ok(unk != &test_outer, "Returned IUnknown should not be outer IUnknown.\n");
ref = get_refcount(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
ref = IUnknown_AddRef(unk);
- ok(ref == 2, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 2, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
ref = IUnknown_Release(unk);
- ok(ref == 1, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(ref == 1, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
hr = IUnknown_QueryInterface(unk, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == unk, "Got unexpected IUnknown %p.\n", unk2);
IUnknown_Release(unk2);
hr = IUnknown_QueryInterface(unk, &IID_IAMTimeline, (void **)&timeline);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IAMTimeline_QueryInterface(timeline, &IID_IUnknown, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
hr = IAMTimeline_QueryInterface(timeline, &IID_IAMTimeline, (void **)&timeline2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(timeline2 == (IAMTimeline *)0xdeadbeef, "Got unexpected IAMTimeline %p.\n", timeline2);
hr = IUnknown_QueryInterface(unk, &test_iid, (void **)&unk2);
- ok(hr == E_NOINTERFACE, "Got hr %#x.\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!unk2, "Got unexpected IUnknown %p.\n", unk2);
hr = IAMTimeline_QueryInterface(timeline, &test_iid, (void **)&unk2);
- ok(hr == S_OK, "Got hr %#x.\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(unk2 == (IUnknown *)0xdeadbeef, "Got unexpected IUnknown %p.\n", unk2);
IAMTimeline_Release(timeline);
ref = IUnknown_Release(unk);
- ok(!ref, "Got unexpected refcount %d.\n", ref);
- ok(outer_ref == 1, "Got unexpected refcount %d.\n", outer_ref);
+ ok(!ref, "Got unexpected refcount %ld.\n", ref);
+ ok(outer_ref == 1, "Got unexpected refcount %ld.\n", outer_ref);
}
static void test_timeline(void)
@@ -133,21 +133,21 @@ static void test_timeline(void)
TIMELINE_MAJOR_TYPE type;
hr = CoCreateInstance(&CLSID_AMTimeline, NULL, CLSCTX_INPROC_SERVER, &IID_IAMTimeline, (void **)&timeline);
- ok(hr == S_OK || broken(hr == REGDB_E_CLASSNOTREG), "CoCreateInstance failed: %08x\n", hr);
+ ok(hr == S_OK || broken(hr == REGDB_E_CLASSNOTREG), "Got hr %#lx.\n", hr);
if (!timeline) return;
hr = IAMTimeline_QueryInterface(timeline, &IID_IAMTimelineObj, NULL);
- ok(hr == E_POINTER, "Expected E_POINTER got %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IAMTimeline_QueryInterface(timeline, &IID_IAMTimelineObj, (void **)&obj);
- ok(hr == E_NOINTERFACE, "Expected E_NOINTERFACE got %08x\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!obj, "Expected NULL got %p\n", obj);
hr = IAMTimeline_CreateEmptyNode(timeline, NULL, 0);
- ok(hr == E_POINTER, "Expected E_POINTER got %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IAMTimeline_CreateEmptyNode(timeline, NULL, TIMELINE_MAJOR_TYPE_COMPOSITE);
- ok(hr == E_POINTER, "Expected E_POINTER got %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
for (type = 0; type < 256; type++)
{
@@ -161,49 +161,49 @@ static void test_timeline(void)
case TIMELINE_MAJOR_TYPE_TRANSITION:
case TIMELINE_MAJOR_TYPE_EFFECT:
case TIMELINE_MAJOR_TYPE_GROUP:
- ok(hr == S_OK, "CreateEmptyNode failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
if (obj != &obj_iface) IAMTimelineObj_Release(obj);
break;
default:
- ok(hr == E_INVALIDARG, "Expected E_INVALIDARG got %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
ok(obj == &obj_iface, "Expected %p got %p\n", &obj_iface, obj);
}
}
obj = NULL;
hr = IAMTimeline_CreateEmptyNode(timeline, &obj, TIMELINE_MAJOR_TYPE_COMPOSITE);
- ok(hr == S_OK, "CreateEmptyNode failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
if (!obj) return;
hr = IAMTimelineObj_QueryInterface(obj, &IID_IAMTimeline, NULL);
- ok(hr == E_POINTER, "Expected E_POINTER got %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IAMTimelineObj_QueryInterface(obj, &IID_IAMTimeline, (void **)&timeline2);
- ok(hr == E_NOINTERFACE, "Expected E_NOINTERFACE got %08x\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!timeline2, "Expected NULL got %p\n", timeline2);
hr = IAMTimelineObj_GetTimelineType(obj, NULL);
- ok(hr == E_POINTER, "Expected E_POINTER got %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
hr = IAMTimelineObj_GetTimelineType(obj, &type);
- ok(hr == S_OK, "GetTimelineType failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(type == TIMELINE_MAJOR_TYPE_COMPOSITE, "Expected TIMELINE_MAJOR_TYPE_COMPOSITE got %d\n", type);
for (type = 0; type < 256; type++)
{
hr = IAMTimelineObj_SetTimelineType(obj, type);
if (type == TIMELINE_MAJOR_TYPE_COMPOSITE)
- ok(hr == S_OK, "SetTimelineType failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
else
- ok(hr == E_INVALIDARG, "Expected E_INVALIDARG got %08x\n", hr);
+ ok(hr == E_INVALIDARG, "Got hr %#lx.\n", hr);
}
hr = IAMTimelineObj_GetTimelineNoRef(obj, NULL);
- ok(hr == E_POINTER, "Expected E_POINTER got %08x\n", hr);
+ ok(hr == E_POINTER, "Got hr %#lx.\n", hr);
timeline2 = (IAMTimeline *)0xdeadbeef;
hr = IAMTimelineObj_GetTimelineNoRef(obj, &timeline2);
- ok(hr == E_NOINTERFACE, "Expected E_NOINTERFACE got %08x\n", hr);
+ ok(hr == E_NOINTERFACE, "Got hr %#lx.\n", hr);
ok(!timeline2, "Expected NULL got %p\n", timeline2);
IAMTimelineObj_Release(obj);
@@ -217,22 +217,22 @@ static void test_timelineobj_interfaces(void)
IAMTimelineObj *obj;
hr = CoCreateInstance(&CLSID_AMTimeline, NULL, CLSCTX_INPROC_SERVER, &IID_IAMTimeline, (void **)&timeline);
- ok(hr == S_OK || broken(hr == REGDB_E_CLASSNOTREG), "CoCreateInstance failed: %08x\n", hr);
+ ok(hr == S_OK || broken(hr == REGDB_E_CLASSNOTREG), "Got hr %#lx.\n", hr);
if (!timeline)
return;
hr = IAMTimeline_CreateEmptyNode(timeline, &obj, TIMELINE_MAJOR_TYPE_GROUP);
- ok(hr == S_OK, "CreateEmptyNode failed: %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
if(hr == S_OK)
{
IAMTimelineGroup *group;
IAMTimelineObj *obj2;
hr = IAMTimelineObj_QueryInterface(obj, &IID_IAMTimelineGroup, (void **)&group);
- ok(hr == S_OK, "got %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
hr = IAMTimelineGroup_QueryInterface(group, &IID_IAMTimelineObj, (void **)&obj2);
- ok(hr == S_OK, "got %08x\n", hr);
+ ok(hr == S_OK, "Got hr %#lx.\n", hr);
ok(obj == obj2, "Different pointers\n");
IAMTimelineObj_Release(obj2);
@@ -255,7 +255,7 @@ START_TEST(timeline)
&IID_IAMTimeline, (void **)&timeline)))
{
/* qedit.dll does not exist on 2003. */
- win_skip("Failed to create timeline object, hr %#x.\n", hr);
+ win_skip("Failed to create timeline object, hr %#lx.\n", hr);
return;
}
IAMTimeline_Release(timeline);
--
2.35.1
More information about the wine-devel
mailing list