From bd102b527690dd4e937021da82f6f68b3a6573d3 Mon Sep 17 00:00:00 2001 From: Nikolay Sivov Date: Sun, 19 Aug 2012 19:11:05 +0400 Subject: [PATCH] amstream: Call interface methods properly. --- dlls/amstream/amstream.c | 6 +++--- dlls/amstream/audiodata.c | 2 +- dlls/amstream/mediastream.c | 4 ++-- dlls/amstream/tests/amstream.c | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/dlls/amstream/amstream.c b/dlls/amstream/amstream.c index c61fcd06576..293e2b917c3 100644 --- a/dlls/amstream/amstream.c +++ b/dlls/amstream/amstream.c @@ -87,8 +87,8 @@ static HRESULT WINAPI IAMMultiMediaStreamImpl_QueryInterface(IAMMultiMediaStream IsEqualGUID(riid, &IID_IMultiMediaStream) || IsEqualGUID(riid, &IID_IAMMultiMediaStream)) { - IUnknown_AddRef(iface); - *ppvObject = This; + IAMMultiMediaStream_AddRef(iface); + *ppvObject = iface; return S_OK; } @@ -306,7 +306,7 @@ static HRESULT WINAPI IAMMultiMediaStreamImpl_GetFilterGraph(IAMMultiMediaStream return E_POINTER; if (This->pFilterGraph) - return IFilterGraph_QueryInterface(This->pFilterGraph, &IID_IGraphBuilder, (void**)ppGraphBuilder); + return IGraphBuilder_QueryInterface(This->pFilterGraph, &IID_IGraphBuilder, (void**)ppGraphBuilder); else *ppGraphBuilder = NULL; diff --git a/dlls/amstream/audiodata.c b/dlls/amstream/audiodata.c index 7d3c38a2d54..2bd57da4b26 100644 --- a/dlls/amstream/audiodata.c +++ b/dlls/amstream/audiodata.c @@ -48,7 +48,7 @@ static HRESULT WINAPI IAudioDataImpl_QueryInterface(IAudioData *iface, REFIID ri IsEqualGUID(riid, &IID_IMemoryData) || IsEqualGUID(riid, &IID_IAudioData)) { - IUnknown_AddRef(iface); + IAudioData_AddRef(iface); *ret_iface = iface; return S_OK; } diff --git a/dlls/amstream/mediastream.c b/dlls/amstream/mediastream.c index 6656bf725cc..295796b5c3b 100644 --- a/dlls/amstream/mediastream.c +++ b/dlls/amstream/mediastream.c @@ -60,8 +60,8 @@ static HRESULT WINAPI IDirectDrawMediaStreamImpl_QueryInterface(IDirectDrawMedia IsEqualGUID(riid, &IID_IMediaStream) || IsEqualGUID(riid, &IID_IDirectDrawMediaStream)) { - IUnknown_AddRef(iface); - *ppv = This; + IDirectDrawMediaStream_AddRef(iface); + *ppv = iface; return S_OK; } diff --git a/dlls/amstream/tests/amstream.c b/dlls/amstream/tests/amstream.c index ffc6fe03f34..06fb3301eac 100644 --- a/dlls/amstream/tests/amstream.c +++ b/dlls/amstream/tests/amstream.c @@ -155,7 +155,7 @@ static void test_renderfile(void) error: if (pddsample) - IDirectDrawMediaSample_Release(pddsample); + IDirectDrawStreamSample_Release(pddsample); if (pddstream) IDirectDrawMediaStream_Release(pddstream); if (pvidstream) @@ -260,7 +260,7 @@ static void test_media_streams(void) } if (ddraw_sample) - IDirectDrawMediaSample_Release(ddraw_sample); + IDirectDrawStreamSample_Release(ddraw_sample); if (ddraw_stream) IDirectDrawMediaStream_Release(ddraw_stream); }