Commit ad576b69 authored by Michael Stefaniuc's avatar Michael Stefaniuc Committed by Alexandre Julliard

strmbase: Use the ARRAY_SIZE() macro.

parent 640fe968
...@@ -251,7 +251,7 @@ HRESULT WINAPI BaseRenderer_Init(BaseRenderer * This, const IBaseFilterVtbl *Vtb ...@@ -251,7 +251,7 @@ HRESULT WINAPI BaseRenderer_Init(BaseRenderer * This, const IBaseFilterVtbl *Vtb
/* construct input pin */ /* construct input pin */
piInput.dir = PINDIR_INPUT; piInput.dir = PINDIR_INPUT;
piInput.pFilter = &This->filter.IBaseFilter_iface; piInput.pFilter = &This->filter.IBaseFilter_iface;
lstrcpynW(piInput.achName, wcsInputPinName, sizeof(piInput.achName) / sizeof(piInput.achName[0])); lstrcpynW(piInput.achName, wcsInputPinName, ARRAY_SIZE(piInput.achName));
hr = BaseInputPin_Construct(&BaseRenderer_InputPin_Vtbl, sizeof(BaseInputPin), &piInput, hr = BaseInputPin_Construct(&BaseRenderer_InputPin_Vtbl, sizeof(BaseInputPin), &piInput,
&input_BaseInputFuncTable, &This->filter.csFilter, NULL, (IPin **)&This->pInputPin); &input_BaseInputFuncTable, &This->filter.csFilter, NULL, (IPin **)&This->pInputPin);
......
...@@ -210,10 +210,10 @@ static HRESULT TransformFilter_Init(const IBaseFilterVtbl *pVtbl, const CLSID* p ...@@ -210,10 +210,10 @@ static HRESULT TransformFilter_Init(const IBaseFilterVtbl *pVtbl, const CLSID* p
/* construct input pin */ /* construct input pin */
piInput.dir = PINDIR_INPUT; piInput.dir = PINDIR_INPUT;
piInput.pFilter = &pTransformFilter->filter.IBaseFilter_iface; piInput.pFilter = &pTransformFilter->filter.IBaseFilter_iface;
lstrcpynW(piInput.achName, wcsInputPinName, sizeof(piInput.achName) / sizeof(piInput.achName[0])); lstrcpynW(piInput.achName, wcsInputPinName, ARRAY_SIZE(piInput.achName));
piOutput.dir = PINDIR_OUTPUT; piOutput.dir = PINDIR_OUTPUT;
piOutput.pFilter = &pTransformFilter->filter.IBaseFilter_iface; piOutput.pFilter = &pTransformFilter->filter.IBaseFilter_iface;
lstrcpynW(piOutput.achName, wcsOutputPinName, sizeof(piOutput.achName) / sizeof(piOutput.achName[0])); lstrcpynW(piOutput.achName, wcsOutputPinName, ARRAY_SIZE(piOutput.achName));
hr = BaseInputPin_Construct(&TransformFilter_InputPin_Vtbl, sizeof(BaseInputPin), &piInput, hr = BaseInputPin_Construct(&TransformFilter_InputPin_Vtbl, sizeof(BaseInputPin), &piInput,
&tf_input_BaseInputFuncTable, &pTransformFilter->filter.csFilter, NULL, &pTransformFilter->ppPins[0]); &tf_input_BaseInputFuncTable, &pTransformFilter->filter.csFilter, NULL, &pTransformFilter->ppPins[0]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment