Module: wine Branch: master Commit: 35ce56ac859793fcecb223b357f414e405281b61 URL: http://source.winehq.org/git/wine.git/?a=commit;h=35ce56ac859793fcecb223b357...
Author: Hans Leidekker hans@codeweavers.com Date: Tue Nov 4 10:57:13 2014 +0100
msi: Pass a database pointer to msi_clone_properties instead of a package pointer.
---
dlls/msi/action.c | 2 +- dlls/msi/msipriv.h | 2 +- dlls/msi/package.c | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-)
diff --git a/dlls/msi/action.c b/dlls/msi/action.c index 66c2858..eb7ac62 100644 --- a/dlls/msi/action.c +++ b/dlls/msi/action.c @@ -7814,7 +7814,7 @@ UINT MSI_InstallPackage( MSIPACKAGE *package, LPCWSTR szPackagePath, }
/* properties may have been added by a transform */ - msi_clone_properties( package ); + msi_clone_properties( package->db ); msi_set_original_database_property( package->db, szPackagePath );
msi_parse_command_line( package, szCommandLine, FALSE ); diff --git a/dlls/msi/msipriv.h b/dlls/msi/msipriv.h index bf788ba..a66835e 100644 --- a/dlls/msi/msipriv.h +++ b/dlls/msi/msipriv.h @@ -864,7 +864,7 @@ extern UINT MSI_SetFeatureStateW(MSIPACKAGE*, LPCWSTR, INSTALLSTATE ) DECLSPEC_H extern UINT msi_download_file( LPCWSTR szUrl, LPWSTR filename ) DECLSPEC_HIDDEN; extern UINT msi_package_add_info(MSIPACKAGE *, DWORD, DWORD, LPCWSTR, LPWSTR) DECLSPEC_HIDDEN; extern UINT msi_package_add_media_disk(MSIPACKAGE *, DWORD, DWORD, DWORD, LPWSTR, LPWSTR) DECLSPEC_HIDDEN; -extern UINT msi_clone_properties(MSIPACKAGE *) DECLSPEC_HIDDEN; +extern UINT msi_clone_properties(MSIDATABASE *) DECLSPEC_HIDDEN; extern UINT msi_set_context(MSIPACKAGE *) DECLSPEC_HIDDEN; extern void msi_adjust_privilege_properties(MSIPACKAGE *) DECLSPEC_HIDDEN; extern UINT MSI_GetFeatureCost(MSIPACKAGE *, MSIFEATURE *, MSICOSTTREE, INSTALLSTATE, LPINT) DECLSPEC_HIDDEN; diff --git a/dlls/msi/package.c b/dlls/msi/package.c index 2805003..c910d82 100644 --- a/dlls/msi/package.c +++ b/dlls/msi/package.c @@ -386,7 +386,7 @@ static UINT create_temp_property_table(MSIPACKAGE *package) return rc; }
-UINT msi_clone_properties(MSIPACKAGE *package) +UINT msi_clone_properties( MSIDATABASE *db ) { static const WCHAR query_select[] = { 'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ', @@ -403,7 +403,7 @@ UINT msi_clone_properties(MSIPACKAGE *package) MSIQUERY *view_select; UINT rc;
- rc = MSI_DatabaseOpenViewW( package->db, query_select, &view_select ); + rc = MSI_DatabaseOpenViewW( db, query_select, &view_select ); if (rc != ERROR_SUCCESS) return rc;
@@ -424,7 +424,7 @@ UINT msi_clone_properties(MSIPACKAGE *package) if (rc != ERROR_SUCCESS) break;
- rc = MSI_DatabaseOpenViewW( package->db, query_insert, &view_insert ); + rc = MSI_DatabaseOpenViewW( db, query_insert, &view_insert ); if (rc != ERROR_SUCCESS) { msiobj_release( &rec_select->hdr ); @@ -440,7 +440,7 @@ UINT msi_clone_properties(MSIPACKAGE *package)
TRACE("insert failed, trying update\n");
- rc = MSI_DatabaseOpenViewW( package->db, query_update, &view_update ); + rc = MSI_DatabaseOpenViewW( db, query_update, &view_update ); if (rc != ERROR_SUCCESS) { WARN("open view failed %u\n", rc); @@ -1175,7 +1175,7 @@ MSIPACKAGE *MSI_CreatePackage( MSIDATABASE *db, LPCWSTR base_url ) package->BaseURL = strdupW( base_url );
create_temp_property_table( package ); - msi_clone_properties( package ); + msi_clone_properties( package->db ); msi_adjust_privilege_properties( package );
package->ProductCode = msi_dup_property( package->db, szProductCode ); @@ -1679,7 +1679,7 @@ UINT MSI_OpenPackageW(LPCWSTR szPackage, MSIPACKAGE **pPackage) } if (index) { - msi_clone_properties( package ); + msi_clone_properties( package->db ); msi_adjust_privilege_properties( package ); } r = msi_set_original_database_property( package->db, szPackage );