diff options
author | hajny <hajny@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2017-02-13 00:03:15 +0000 |
---|---|---|
committer | hajny <hajny@3ad0048d-3df7-0310-abae-a5850022a9f2> | 2017-02-13 00:03:15 +0000 |
commit | ca44198a15c090df65c964912ff36ceaaa5b1fcb (patch) | |
tree | bd1cb1f169f657a62941fcdfb03807eecf47793a /installer | |
parent | 13f34344e2033b50be0bd2b389eb344981909602 (diff) | |
download | fpc-ca44198a15c090df65c964912ff36ceaaa5b1fcb.tar.gz |
* fix base path handling - ensure using full path in the cfg files and avoid double slashes
git-svn-id: http://svn.freepascal.org/svn/fpc/trunk@35433 3ad0048d-3df7-0310-abae-a5850022a9f2
Diffstat (limited to 'installer')
-rw-r--r-- | installer/install.pas | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/installer/install.pas b/installer/install.pas index 74a959fffd..80a7cc9d96 100644 --- a/installer/install.pas +++ b/installer/install.pas @@ -1331,6 +1331,9 @@ end; messagebox('Please, choose the directory for installation first.',nil,mferror+mfokbutton) else begin + Data.BasePath := FExpand (Data.BasePath); + if Data.BasePath [Length (Data.BasePath)] = DirSep then + Dec (Data.BasePath [0]); found:=false; for j:=1 to cfg.packs do if data.packmask[j]>0 then @@ -1362,9 +1365,7 @@ end; end; WriteLog ('Diskspace needed: ' + DotStr (DSize) + ' Kb'); - S := FExpand (Data.BasePath); - if S [Length (S)] = DirSep then - Dec (S [0]); + S := Data.BasePath; Space := DiskFree (byte (Upcase(S [1])) - 64); { -1 means that the drive is invalid } if Space=-1 then |