From e38fa292fb3ac261bdb85bdef6f83f8d5b99bcbb Mon Sep 17 00:00:00 2001 From: Sergey Guralnik Date: Wed, 8 Jan 2014 09:38:51 +0200 Subject: Revert "msi: Use registered SourceDir only for the same product version. (eterbug #8884)" This reverts commit b62628ab2734b5e893aa89bf69297dd27fa57ab3. --- dlls/msi/action.c | 30 ++++++------------------------ 1 file changed, 6 insertions(+), 24 deletions(-) diff --git a/dlls/msi/action.c b/dlls/msi/action.c index 4a521f8..4f1e5d7 100644 --- a/dlls/msi/action.c +++ b/dlls/msi/action.c @@ -423,35 +423,17 @@ static BOOL ui_sequence_exists( MSIPACKAGE *package ) UINT msi_set_sourcedir_props(MSIPACKAGE *package, BOOL replace) { - LPWSTR source = NULL, check; + LPWSTR source, check; if (msi_get_property_int( package->db, szInstalled, 0 )) { - LPWSTR ver; + HKEY hkey; - /* We have registered SourceDir. Use this value if package version and - * installed version are match */ - ver = msi_dup_property( package->db, szProductVersion ); - if(ver) - { - HKEY hkey; - DWORD ms1, ms2, ls1, ls2; - - msi_parse_version_string( ver, &ms1, &ls1 ); - msi_free( ver ); - MSIREG_OpenInstallProps( package->ProductCode, package->Context, NULL, &hkey, FALSE ); - ver = msi_reg_get_val_str( hkey, INSTALLPROPERTY_VERSIONSTRINGW ); - if(ver) - { - msi_parse_version_string(ver, &ms2, &ls2); - if( ms1 == ms2 && ls1 == ls2 ) - source = msi_reg_get_val_str( hkey, INSTALLPROPERTY_INSTALLSOURCEW ); - } - RegCloseKey( hkey ); - } + MSIREG_OpenInstallProps( package->ProductCode, package->Context, NULL, &hkey, FALSE ); + source = msi_reg_get_val_str( hkey, INSTALLPROPERTY_INSTALLSOURCEW ); + RegCloseKey( hkey ); } - - if(!source) + else { LPWSTR p, db; DWORD len; -- 1.7.9.5