Commit 823c418d authored by Joris Huizer's avatar Joris Huizer Committed by Alexandre Julliard

Added IClassFactory->CreateInstance aggregation checks.

parent f971902a
......@@ -47,6 +47,9 @@ HRESULT AM_create(IUnknown *pUnkOuter, LPVOID *ppObj)
FIXME("(%p,%p)\n", pUnkOuter, ppObj);
if( pUnkOuter )
return CLASS_E_NOAGGREGATION;
object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IAMMultiMediaStreamImpl));
object->lpVtbl.lpVtbl = &AM_Vtbl;
......
......@@ -384,6 +384,9 @@ static HRESULT ITSS_create(IUnknown *pUnkOuter, LPVOID *ppObj)
{
ITStorageImpl *its;
if( pUnkOuter )
return CLASS_E_NOAGGREGATION;
its = HeapAlloc( GetProcessHeap(), 0, sizeof(ITStorageImpl) );
its->vtbl_IITStorage = &ITStorageImpl_Vtbl;
its->ref = 1;
......
......@@ -293,7 +293,12 @@ static HRESULT GetClassMediaFile(IAsyncReader * pReader, LPCOLESTR pszFileName,
HRESULT AsyncReader_create(IUnknown * pUnkOuter, LPVOID * ppv)
{
AsyncReader * pAsyncRead = CoTaskMemAlloc(sizeof(AsyncReader));
AsyncReader *pAsyncRead;
if( pUnkOuter )
return CLASS_E_NOAGGREGATION;
pAsyncRead = CoTaskMemAlloc(sizeof(AsyncReader));
if (!pAsyncRead)
return E_OUTOFMEMORY;
......
......@@ -2416,6 +2416,9 @@ HRESULT FILTERGRAPH_create(IUnknown *pUnkOuter, LPVOID *ppObj) {
TRACE("(%p,%p)\n", pUnkOuter, ppObj);
if( pUnkOuter )
return CLASS_E_NOAGGREGATION;
fimpl = (IFilterGraphImpl *) HeapAlloc(GetProcessHeap(), 0, sizeof(*fimpl));
fimpl->IGraphBuilder_vtbl = &IGraphBuilder_VTable;
fimpl->IMediaControl_vtbl = &IMediaControl_VTable;
......
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