|
@@ -86,14 +86,14 @@ begin
|
|
begin
|
|
begin
|
|
I := GetNextWordPos (Params);
|
|
I := GetNextWordPos (Params);
|
|
ExecName := Copy (Params, 1, Pred (I));
|
|
ExecName := Copy (Params, 1, Pred (I));
|
|
- Trim (ExecName);
|
|
|
|
|
|
+ ExecName := Trim (ExecName);
|
|
Delete (Params, 1, Pred (I));
|
|
Delete (Params, 1, Pred (I));
|
|
end
|
|
end
|
|
else if Copy (FCommandLine, 1, Length (ExecName)) = ExecName then
|
|
else if Copy (FCommandLine, 1, Length (ExecName)) = ExecName then
|
|
Delete (Params, 1, Succ (Length (ExecName)))
|
|
Delete (Params, 1, Succ (Length (ExecName)))
|
|
else
|
|
else
|
|
Delete (Params, 1, Pred (GetNextWordPos (Params)));
|
|
Delete (Params, 1, Pred (GetNextWordPos (Params)));
|
|
- Trim (Params);
|
|
|
|
|
|
+ Params := Trim (Params);
|
|
end
|
|
end
|
|
else
|
|
else
|
|
for I := 0 to Pred (Parameters.Count) do
|
|
for I := 0 to Pred (Parameters.Count) do
|
|
@@ -113,12 +113,12 @@ begin
|
|
GetDir (0, OrigDir);
|
|
GetDir (0, OrigDir);
|
|
ChDir (FCurrentDirectory);
|
|
ChDir (FCurrentDirectory);
|
|
end;
|
|
end;
|
|
- try
|
|
|
|
|
|
+ try
|
|
cos := BPTR(0);
|
|
cos := BPTR(0);
|
|
repeat
|
|
repeat
|
|
Inc(UID);
|
|
Inc(UID);
|
|
TempName := 'T:PrO_'+ HexStr(FindTask(nil)) + '_' + IntToHex(UID,8);
|
|
TempName := 'T:PrO_'+ HexStr(FindTask(nil)) + '_' + IntToHex(UID,8);
|
|
- until not FileExists(TempName);
|
|
|
|
|
|
+ until not FileExists(TempName);
|
|
//sysdebugln('TProcess start: "' + ExecName + ' ' + Params+'" >' + TempName);
|
|
//sysdebugln('TProcess start: "' + ExecName + ' ' + Params+'" >' + TempName);
|
|
cos := AmigaDos.DosOpen(PChar(TempName), MODE_READWRITE);
|
|
cos := AmigaDos.DosOpen(PChar(TempName), MODE_READWRITE);
|
|
FExitCode := LongInt(amigados.Execute(PChar(ExecName + ' ' + Params), BPTR(0), cos));
|
|
FExitCode := LongInt(amigados.Execute(PChar(ExecName + ' ' + Params), BPTR(0), cos));
|