summaryrefslogtreecommitdiff
path: root/ide/wutils.pas
diff options
context:
space:
mode:
Diffstat (limited to 'ide/wutils.pas')
-rw-r--r--ide/wutils.pas12
1 files changed, 10 insertions, 2 deletions
diff --git a/ide/wutils.pas b/ide/wutils.pas
index 4e890a1994..e7242bc385 100644
--- a/ide/wutils.pas
+++ b/ide/wutils.pas
@@ -514,7 +514,11 @@ function DirOf(const S: string): string;
var D: DirStr; E: ExtStr; N: NameStr;
begin
FSplit(S,D,N,E);
- if (D<>'') and (D[Length(D)]<>DirSep) then
+ if (D<>'') and (D[Length(D)]<>DirSep)
+ {$ifdef HASAMIGA}
+ and (D[Length(D)]<>DriveSeparator)
+ {$endif}
+ then
DirOf:=D+DirSep
else
DirOf:=D;
@@ -1220,7 +1224,11 @@ function GetCurDir: string;
var S: string;
begin
GetDir(0,S);
+{$ifdef HASAMIGA}
+ if (copy(S,length(S),1)<>DirSep) and (copy(S,length(S),1)<>DriveSeparator) then S:=S+DirSep;
+{$else}
if copy(S,length(S),1)<>DirSep then S:=S+DirSep;
+{$endif}
GetCurDir:=S;
end;
@@ -1233,7 +1241,7 @@ var Dir: string;
begin
Dir:=GetEnv('TEMP');
if Dir='' then Dir:=GetEnv('TMP');
-{$if defined(morphos) or defined(amiga)}
+{$ifdef HASAMIGA}
if Dir='' then Dir:='T:';
{$endif}
if (Dir<>'') then if not ExistsDir(Dir) then Dir:='';