mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-15 14:19:28 +02:00
+ Fix for command-line property
This commit is contained in:
parent
29bae36989
commit
973bf7028d
@ -304,9 +304,15 @@ begin
|
||||
Try
|
||||
Argv:=MakeCommand(Self);
|
||||
Try
|
||||
PName:=ApplicationName;
|
||||
If (PName='') then
|
||||
PName:=CommandLine;
|
||||
If (Argv<>Nil) and (ArgV[0]<>Nil) then
|
||||
PName:=StrPas(Argv[0])
|
||||
else
|
||||
begin
|
||||
// This should never happen, actually.
|
||||
PName:=ApplicationName;
|
||||
If (PName='') then
|
||||
PName:=CommandLine;
|
||||
end;
|
||||
if (pos('/',PName)<>1) then
|
||||
PName:=FileSearch(Pname,fpgetenv('PATH'));
|
||||
Pid:=fpfork;
|
||||
|
Loading…
Reference in New Issue
Block a user