dmsynth: The DMSynth{,Sink} COM objects don't support aggregation.

Signed-off-by: Michael Stefaniuc <mstefani@redhat.de>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Michael Stefaniuc 2016-07-19 09:50:58 +02:00 committed by Alexandre Julliard
parent a7e52707b0
commit 91ba1a2561
4 changed files with 11 additions and 8 deletions

View File

@ -32,7 +32,7 @@ LONG DMSYNTH_refCount = 0;
typedef struct {
IClassFactory IClassFactory_iface;
HRESULT WINAPI (*fnCreateInstance)(REFIID riid, void **ppv, IUnknown *pUnkOuter);
HRESULT WINAPI (*fnCreateInstance)(REFIID riid, void **ppv);
} IClassFactoryImpl;
/******************************************************************
@ -84,7 +84,10 @@ static HRESULT WINAPI ClassFactory_CreateInstance(IClassFactory *iface, IUnknown
TRACE ("(%p, %s, %p)\n", pUnkOuter, debugstr_dmguid(riid), ppv);
return This->fnCreateInstance(riid, ppv, pUnkOuter);
if (pUnkOuter)
return CLASS_E_NOAGGREGATION;
return This->fnCreateInstance(riid, ppv);
}
static HRESULT WINAPI ClassFactory_LockServer(IClassFactory *iface, BOOL dolock)

View File

@ -50,8 +50,8 @@ typedef struct IDirectMusicSynthSinkImpl IDirectMusicSynthSinkImpl;
/*****************************************************************************
* ClassFactory
*/
extern HRESULT WINAPI DMUSIC_CreateDirectMusicSynthImpl (LPCGUID lpcGUID, LPVOID* ppobj, LPUNKNOWN pUnkOuter) DECLSPEC_HIDDEN;
extern HRESULT WINAPI DMUSIC_CreateDirectMusicSynthSinkImpl (LPCGUID lpcGUID, LPVOID* ppobj, LPUNKNOWN pUnkOuter) DECLSPEC_HIDDEN;
extern HRESULT WINAPI DMUSIC_CreateDirectMusicSynthImpl(REFIID riid, void **ppobj) DECLSPEC_HIDDEN;
extern HRESULT WINAPI DMUSIC_CreateDirectMusicSynthSinkImpl(REFIID riid, void **ppobj) DECLSPEC_HIDDEN;
/*****************************************************************************
* IDirectMusicSynth8Impl implementation structure

View File

@ -575,14 +575,14 @@ static const IKsControlVtbl DMSynthImpl_IKsControl_Vtbl = {
};
/* for ClassFactory */
HRESULT WINAPI DMUSIC_CreateDirectMusicSynthImpl(REFIID riid, void **ppobj, IUnknown *outer)
HRESULT WINAPI DMUSIC_CreateDirectMusicSynthImpl(REFIID riid, void **ppobj)
{
static const WCHAR descrW[] = {'M','i','c','r','o','s','o','f','t',' ',
'S','y','n','t','h','e','s','i','z','e','r',0};
IDirectMusicSynth8Impl *obj;
HRESULT hr;
TRACE("(%s, %p, %p)\n", debugstr_guid(riid), ppobj, outer);
TRACE("(%s, %p)\n", debugstr_guid(riid), ppobj);
obj = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*obj));
if (NULL == obj) {

View File

@ -267,12 +267,12 @@ static const IKsControlVtbl DMSynthSinkImpl_IKsControl_Vtbl = {
};
/* for ClassFactory */
HRESULT WINAPI DMUSIC_CreateDirectMusicSynthSinkImpl(LPCGUID riid, LPVOID* ret_iface, LPUNKNOWN unkouter)
HRESULT WINAPI DMUSIC_CreateDirectMusicSynthSinkImpl(REFIID riid, void **ret_iface)
{
IDirectMusicSynthSinkImpl *obj;
HRESULT hr;
TRACE("(%p,%p,%p)\n", riid, ret_iface, unkouter);
TRACE("(%s, %p)\n", debugstr_guid(riid), ret_iface);
*ret_iface = NULL;