Merged revision(s) 59382 #a579366c3f, 59384 #7720c8bd0a from trunk:

Installer, Win: Allow adjusting install dir, in case of 2ndary/multiple installs.
........
Installer, Win: Prevent a crash, if installing 2ndary into same path, as previous (removed) primary installation. / Added logging.
........

git-svn-id: branches/fixes_2_0@59391 -
This commit is contained in:
maxim 2018-10-29 23:04:41 +00:00
parent a8374659df
commit 1249e33845
2 changed files with 8 additions and 0 deletions

View File

@ -103,6 +103,7 @@ begin
if UninstallState = uiDone then exit;
UnInstaller := RemoveQuotes(GetUninstallData('UninstallString'));
Log(' UnInstaller: '+UnInstaller);
if (UnInstaller <> '') and FileExists(UnInstaller) then
begin
OldPath := RemoveQuotes((GetUninstallData('Inno Setup: App Path')));
@ -110,6 +111,7 @@ begin
PathEqual := (OldPath <> '') and
(CompareText(RemoveBackslashUnlessRoot(OldPath), RemoveBackslashUnlessRoot(WizardDirValue)) = 0);
Log(' OldPath: '+OldPath+' OldName: '+ OldName);
if PathEqual then
UninstallState := uiDestNeeded
else
@ -128,6 +130,11 @@ begin
begin
if (IsSecondaryCheckBoxChecked) or IsSecondaryUpdate then
begin
if ForcePrimaryAppId then begin
Log('UpdateUninstallInfo recursion detected');
UninstallState := uiInconsistent;
exit;
end;
ForcePrimaryAppId := True;
Log('REDO UninstallState '+GetUninstallData('Inno Setup: App Path')+' // '+WizardDirValue);
if CompareText(RemoveBackslashUnlessRoot(RemoveQuotes(GetUninstallData('Inno Setup: App Path'))),

View File

@ -56,6 +56,7 @@ ShowTasksTreeLines=true
PrivilegesRequired=none
; since appid can change, UsePreviousLanguage must be off
UsePreviousLanguage=no
DisableDirPage=no
[Files]
Source: {#BuildDir}\image\*.*; DestDir: {app}; Flags: recursesubdirs