mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-18 11:59:20 +02:00
MG: fixed trailing space in commandline of tools
git-svn-id: trunk@461 -
This commit is contained in:
parent
1a07b8319a
commit
e65de1397a
@ -221,7 +221,7 @@ end;
|
|||||||
|
|
||||||
function TExternalToolList.Run(Index: integer;
|
function TExternalToolList.Run(Index: integer;
|
||||||
Macros: TTransferMacroList): TModalResult;
|
Macros: TTransferMacroList): TModalResult;
|
||||||
var WorkingDir, Filename, Params: string;
|
var WorkingDir, Filename, Params, CmdLine: string;
|
||||||
TheProcess: TProcess;
|
TheProcess: TProcess;
|
||||||
begin
|
begin
|
||||||
Result:=mrCancel;
|
Result:=mrCancel;
|
||||||
@ -232,10 +232,13 @@ begin
|
|||||||
if Macros.SubstituteStr(Filename)
|
if Macros.SubstituteStr(Filename)
|
||||||
and Macros.SubstituteStr(WorkingDir)
|
and Macros.SubstituteStr(WorkingDir)
|
||||||
and Macros.SubstituteStr(Params) then begin
|
and Macros.SubstituteStr(Params) then begin
|
||||||
writeln('[TExternalToolList.Run] ',Filename,' ',Params);
|
CmdLine:=Filename;
|
||||||
|
if Params<>'' then
|
||||||
|
CmdLine:=CmdLine+' '+Params;
|
||||||
|
writeln('[TExternalToolList.Run] ',CmdLine);
|
||||||
try
|
try
|
||||||
CheckIfFileIsExecutable(Filename);
|
CheckIfFileIsExecutable(Filename);
|
||||||
TheProcess:=TProcess.Create(Filename+' '+Params,[poRunSuspended,
|
TheProcess:=TProcess.Create(CmdLine,[poRunSuspended,
|
||||||
poUsePipes, poNoConsole]);
|
poUsePipes, poNoConsole]);
|
||||||
TheProcess.CurrentDirectory:=WorkingDir;
|
TheProcess.CurrentDirectory:=WorkingDir;
|
||||||
{TheProcess := TProcess.Create(nil);
|
{TheProcess := TProcess.Create(nil);
|
||||||
|
Loading…
Reference in New Issue
Block a user