Module: wine Branch: master Commit: 6a588baaf7ecbe01ed0dc71c8610ff9f18e8eb3c URL: http://source.winehq.org/git/wine.git/?a=commit;h=6a588baaf7ecbe01ed0dc71c86...
Author: Hans Leidekker hans@codeweavers.com Date: Fri Jul 27 14:03:12 2012 +0200
msi: Use inline wrappers for calling COM methods.
---
dlls/msi/Makefile.in | 1 + dlls/msi/automation.c | 3 +-- dlls/msi/custom.c | 2 +- dlls/msi/database.c | 8 ++++---- dlls/msi/package.c | 2 +- dlls/msi/script.c | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/dlls/msi/Makefile.in b/dlls/msi/Makefile.in index 140b5f1..9ea0861 100644 --- a/dlls/msi/Makefile.in +++ b/dlls/msi/Makefile.in @@ -2,6 +2,7 @@ MODULE = msi.dll IMPORTLIB = msi IMPORTS = uuid urlmon wininet comctl32 shell32 shlwapi cabinet oleaut32 ole32 version user32 gdi32 advapi32 DELAYIMPORTS = odbccp32 wintrust crypt32 imagehlp +EXTRADEFS = -DWIDL_C_INLINE_WRAPPERS
C_SRCS = \ action.c \ diff --git a/dlls/msi/automation.c b/dlls/msi/automation.c index 918572a..e55717a 100644 --- a/dlls/msi/automation.c +++ b/dlls/msi/automation.c @@ -609,8 +609,7 @@ static HRESULT WINAPI ListEnumerator_Clone(IEnumVARIANT* iface, IEnumVARIANT **p hr = create_list_enumerator(This->list, (LPVOID *)ppEnum); if (FAILED(hr)) { - if (*ppEnum) - IUnknown_Release(*ppEnum); + if (*ppEnum) IEnumVARIANT_Release(*ppEnum); return hr; }
diff --git a/dlls/msi/custom.c b/dlls/msi/custom.c index 88dcf87..8f32e59 100644 --- a/dlls/msi/custom.c +++ b/dlls/msi/custom.c @@ -1439,7 +1439,7 @@ static HRESULT WINAPI mcr_QueryInterface( IWineMsiRemoteCustomAction *iface, if( IsEqualCLSID( riid, &IID_IUnknown ) || IsEqualCLSID( riid, &IID_IWineMsiRemoteCustomAction ) ) { - IUnknown_AddRef( iface ); + IWineMsiRemoteCustomAction_AddRef( iface ); *ppobj = iface; return S_OK; } diff --git a/dlls/msi/database.c b/dlls/msi/database.c index 1f3ab81..9c0d346 100644 --- a/dlls/msi/database.c +++ b/dlls/msi/database.c @@ -164,7 +164,7 @@ UINT msi_get_raw_stream( MSIDATABASE *db, LPCWSTR stname, IStream **stm )
if (!(stream = msi_alloc( sizeof(MSISTREAM) ))) return ERROR_NOT_ENOUGH_MEMORY; stream->stg = stg; - IStream_AddRef( stg ); + IStorage_AddRef( stg ); stream->stm = *stm; IStream_AddRef( *stm ); list_add_tail( &db->streams, &stream->entry ); @@ -207,7 +207,7 @@ void msi_destroy_stream( MSIDATABASE *db, const WCHAR *stname )
list_remove( &stream->entry ); IStream_Release( stream->stm ); - IStream_Release( stream->stg ); + IStorage_Release( stream->stg ); IStorage_DestroyElement( stream->stg, stname ); msi_free( stream ); CoTaskMemFree( stat.pwcsName ); @@ -224,7 +224,7 @@ static void free_streams( MSIDATABASE *db ) MSISTREAM *s = LIST_ENTRY(list_head( &db->streams ), MSISTREAM, entry); list_remove( &s->entry ); IStream_Release( s->stm ); - IStream_Release( s->stg ); + IStorage_Release( s->stg ); msi_free( s ); } } @@ -2082,7 +2082,7 @@ static HRESULT WINAPI mrd_QueryInterface( IWineMsiRemoteDatabase *iface, if( IsEqualCLSID( riid, &IID_IUnknown ) || IsEqualCLSID( riid, &IID_IWineMsiRemoteDatabase ) ) { - IUnknown_AddRef( iface ); + IWineMsiRemoteDatabase_AddRef( iface ); *ppobj = iface; return S_OK; } diff --git a/dlls/msi/package.c b/dlls/msi/package.c index 1115942..a050b2e 100644 --- a/dlls/msi/package.c +++ b/dlls/msi/package.c @@ -2361,7 +2361,7 @@ static HRESULT WINAPI mrp_QueryInterface( IWineMsiRemotePackage *iface, if( IsEqualCLSID( riid, &IID_IUnknown ) || IsEqualCLSID( riid, &IID_IWineMsiRemotePackage ) ) { - IUnknown_AddRef( iface ); + IWineMsiRemotePackage_AddRef( iface ); *ppobj = iface; return S_OK; } diff --git a/dlls/msi/script.c b/dlls/msi/script.c index 4866630..94577ba 100644 --- a/dlls/msi/script.c +++ b/dlls/msi/script.c @@ -219,7 +219,7 @@ static HRESULT WINAPI MsiActiveScriptSite_QueryInterface(IActiveScriptSite* ifac if (IsEqualGUID(riid, &IID_IUnknown) || IsEqualGUID(riid, &IID_IActiveScriptSite)) { - IClassFactory_AddRef(iface); + IActiveScriptSite_AddRef(iface); *ppvObject = This; return S_OK; }