From 2c26619f34e5a46504e2c919dec3801e26d377c4 Mon Sep 17 00:00:00 2001 From: Basile Burg Date: Mon, 9 Nov 2015 12:47:58 +0100 Subject: [PATCH] removed superfkuous chdir, already handled by TProcess.currentDirectory --- src/ce_nativeproject.pas | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/ce_nativeproject.pas b/src/ce_nativeproject.pas index 809dcadc..13bbbad9 100644 --- a/src/ce_nativeproject.pas +++ b/src/ce_nativeproject.pas @@ -676,7 +676,7 @@ function TCENativeProject.compile: Boolean; var config: TCompilerConfiguration; compilproc: TProcess; - olddir, prjpath: string; + prjpath: string; prjname: string; msgs: ICEMessagesDisplay; begin @@ -702,15 +702,11 @@ begin // prjname := shortenPath(filename, 25); compilproc := TProcess.Create(nil); - olddir := GetCurrentDir; try msgs.message('compiling ' + prjname, self as ICECommonProject, amcProj, amkInf); prjpath := extractFilePath(fileName); if directoryExists(prjpath) then - begin - chDir(prjpath); compilproc.CurrentDirectory := prjpath; - end; compilproc.Executable := DCompiler; compilproc.Options := compilproc.Options + [poStderrToOutPut, poUsePipes]; compilproc.ShowWindow := swoHIDE; @@ -731,7 +727,6 @@ begin finally updateOutFilename; compilproc.Free; - chDir(olddir); end; end;