From 781e19aa4c60b5b80019b4278f74d266ba8dfe56 Mon Sep 17 00:00:00 2001 From: James Hawkins Date: Sat, 5 Jan 2008 13:46:00 -0700 Subject: [PATCH] msi: OriginalDatabase is the fully-expanded path to the original package if the package is local and installed from the command line. --- dlls/msi/package.c | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/dlls/msi/package.c b/dlls/msi/package.c index d4d0262f561..a8d33e031d2 100644 --- a/dlls/msi/package.c +++ b/dlls/msi/package.c @@ -932,20 +932,18 @@ UINT MSI_OpenPackageW(LPCWSTR szPackage, MSIPACKAGE **pPackage) if( file != szPackage ) track_tempfile( package, file ); + MSI_SetPropertyW( package, Database, db->path ); + if( UrlIsW( szPackage, URLIS_URL ) ) - { - MSI_SetPropertyW( package, OriginalDatabase, szPackage ); - MSI_SetPropertyW( package, Database, db->path ); - } - else if( szPackage[0] != '#' ) - { MSI_SetPropertyW( package, OriginalDatabase, szPackage ); - MSI_SetPropertyW( package, Database, szPackage ); - } + else if( szPackage[0] == '#' ) + MSI_SetPropertyW( package, OriginalDatabase, db->path ); else { - MSI_SetPropertyW( package, OriginalDatabase, db->path ); - MSI_SetPropertyW( package, Database, db->path ); + WCHAR fullpath[MAX_PATH]; + + GetFullPathNameW( szPackage, MAX_PATH, fullpath, NULL ); + MSI_SetPropertyW( package, OriginalDatabase, fullpath ); } *pPackage = package; -- 2.11.4.GIT