Signed-off-by: Michael Stefaniuc mstefani@winehq.org --- dlls/quartz/tests/avisplitter.c | 4 ++-- dlls/quartz/tests/filtergraph.c | 6 +++--- dlls/quartz/tests/misc.c | 8 ++++---- 3 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/dlls/quartz/tests/avisplitter.c b/dlls/quartz/tests/avisplitter.c index 8bafb14157..bc933d148d 100644 --- a/dlls/quartz/tests/avisplitter.c +++ b/dlls/quartz/tests/avisplitter.c @@ -210,7 +210,7 @@ static void test_filesourcefilter(void) ret = GetTempFileNameW(temp, prefix, 0, path); ok(ret, "GetTempFileNameW failed with error %u\n", GetLastError());
- for (i = 0; i < sizeof(tests)/sizeof(tests[0]); i++) + for (i = 0; i < ARRAY_SIZE(tests); i++) { trace("Running test for %s\n", tests[i].label);
@@ -280,7 +280,7 @@ static WCHAR *load_resource(const WCHAR *name) HRSRC res; void *ptr;
- GetTempPathW(sizeof(pathW)/sizeof(WCHAR), pathW); + GetTempPathW(ARRAY_SIZE(pathW), pathW); lstrcatW(pathW, name);
file = CreateFileW(pathW, GENERIC_READ|GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, 0, 0); diff --git a/dlls/quartz/tests/filtergraph.c b/dlls/quartz/tests/filtergraph.c index a1ece9489f..85079d982d 100644 --- a/dlls/quartz/tests/filtergraph.c +++ b/dlls/quartz/tests/filtergraph.c @@ -50,7 +50,7 @@ static WCHAR *load_resource(const WCHAR *name) HRSRC res; void *ptr;
- GetTempPathW(sizeof(pathW)/sizeof(WCHAR), pathW); + GetTempPathW(ARRAY_SIZE(pathW), pathW); lstrcatW(pathW, name);
file = CreateFileW(pathW, GENERIC_READ|GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, 0, 0); @@ -1500,14 +1500,14 @@ static HRESULT createtestfilter(const CLSID* pClsid, const TestFilterPinData *pi pinInfo.pFilter = &pTestFilter->IBaseFilter_iface; if (pinInfo.dir == PINDIR_INPUT) { - lstrcpynW(pinInfo.achName, wcsInputPinName, sizeof(pinInfo.achName) / sizeof(pinInfo.achName[0])); + lstrcpynW(pinInfo.achName, wcsInputPinName, ARRAY_SIZE(pinInfo.achName)); hr = TestFilter_Pin_Construct(&TestFilter_InputPin_Vtbl, &pinInfo, &mt, &pTestFilter->csFilter, &pTestFilter->ppPins[i]);
} else { - lstrcpynW(pinInfo.achName, wcsOutputPinName, sizeof(pinInfo.achName) / sizeof(pinInfo.achName[0])); + lstrcpynW(pinInfo.achName, wcsOutputPinName, ARRAY_SIZE(pinInfo.achName)); hr = TestFilter_Pin_Construct(&TestFilter_OutputPin_Vtbl, &pinInfo, &mt, &pTestFilter->csFilter, &pTestFilter->ppPins[i]); } diff --git a/dlls/quartz/tests/misc.c b/dlls/quartz/tests/misc.c index 748c0f2cfd..16b6d40ce4 100644 --- a/dlls/quartz/tests/misc.c +++ b/dlls/quartz/tests/misc.c @@ -169,7 +169,7 @@ static void test_null_renderer_aggregations(void) }; int i;
- for (i = 0; i < sizeof(iids) / sizeof(iids[0]); i++) + for (i = 0; i < ARRAY_SIZE(iids); i++) { test_aggregation(CLSID_SystemClock, CLSID_NullRenderer, IID_IReferenceClock, *iids[i]); } @@ -182,7 +182,7 @@ static void test_video_renderer_aggregations(void) }; int i;
- for (i = 0; i < sizeof(iids) / sizeof(iids[0]); i++) + for (i = 0; i < ARRAY_SIZE(iids); i++) { test_aggregation(CLSID_SystemClock, CLSID_VideoRenderer, IID_IReferenceClock, *iids[i]); @@ -199,7 +199,7 @@ static void test_filter_graph_aggregations(void) }; int i;
- for (i = 0; i < sizeof(iids) / sizeof(iids[0]); i++) + for (i = 0; i < ARRAY_SIZE(iids); i++) { test_aggregation(CLSID_SystemClock, CLSID_FilterGraph, IID_IReferenceClock, *iids[i]); @@ -213,7 +213,7 @@ static void test_filter_mapper_aggregations(void) }; int i;
- for (i = 0; i < sizeof(iids) / sizeof(iids[0]); i++) + for (i = 0; i < ARRAY_SIZE(iids); i++) { test_aggregation(CLSID_SystemClock, CLSID_FilterMapper2, IID_IReferenceClock, *iids[i]);