mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-19 06:49:16 +02:00
* overloaded ExecuteProcess added, EnvStr param changed to longint
This commit is contained in:
parent
04a8acc442
commit
601f2e02ce
@ -167,7 +167,11 @@ End;
|
|||||||
--- Exec ---
|
--- Exec ---
|
||||||
******************************************************************************}
|
******************************************************************************}
|
||||||
|
|
||||||
|
{$ifdef HASTHREADVAR}
|
||||||
|
threadvar
|
||||||
|
{$else HASTHREADVAR}
|
||||||
var
|
var
|
||||||
|
{$endif HASTHREADVAR}
|
||||||
lastdosexitcode : word;
|
lastdosexitcode : word;
|
||||||
|
|
||||||
procedure exec(const path : pathstr;const comline : comstr);
|
procedure exec(const path : pathstr;const comline : comstr);
|
||||||
@ -892,7 +896,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function envstr(index : integer) : string;
|
function envstr (Index: longint): string;
|
||||||
begin
|
begin
|
||||||
if (index<=0) or (index>envcount) then
|
if (index<=0) or (index>envcount) then
|
||||||
begin
|
begin
|
||||||
@ -946,7 +950,10 @@ End;
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.18 2004-02-09 12:03:16 michael
|
Revision 1.19 2004-02-15 21:34:06 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.18 2004/02/09 12:03:16 michael
|
||||||
+ Switched to single interface in dosh.inc
|
+ Switched to single interface in dosh.inc
|
||||||
|
|
||||||
Revision 1.17 2004/01/06 00:58:35 florian
|
Revision 1.17 2004/01/06 00:58:35 florian
|
||||||
|
@ -782,6 +782,25 @@ begin
|
|||||||
Result := DosExitCode;
|
Result := DosExitCode;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
function ExecuteProcess (const Path: AnsiString;
|
||||||
|
const ComLine: array of AnsiString): integer;
|
||||||
|
|
||||||
|
var
|
||||||
|
CommandLine: AnsiString;
|
||||||
|
I: integer;
|
||||||
|
|
||||||
|
begin
|
||||||
|
Commandline := '';
|
||||||
|
for I := 0 to High (ComLine) do
|
||||||
|
if Pos (' ', ComLine [I]) <> 0 then
|
||||||
|
CommandLine := CommandLine + ' ' + '"' + ComLine [I] + '"'
|
||||||
|
else
|
||||||
|
CommandLine := CommandLine + ' ' + Comline [I];
|
||||||
|
ExecuteProcess := ExecuteProcess (Path, CommandLine);
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
{*************************************************************************
|
{*************************************************************************
|
||||||
Sleep (copied from crt.Delay)
|
Sleep (copied from crt.Delay)
|
||||||
*************************************************************************}
|
*************************************************************************}
|
||||||
@ -860,7 +879,10 @@ Finalization
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.23 2004-01-25 13:05:08 jonas
|
Revision 1.24 2004-02-15 21:34:06 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.23 2004/01/25 13:05:08 jonas
|
||||||
* fixed compilation errors
|
* fixed compilation errors
|
||||||
|
|
||||||
Revision 1.22 2004/01/20 23:09:14 hajny
|
Revision 1.22 2004/01/20 23:09:14 hajny
|
||||||
|
@ -105,7 +105,7 @@ function GetLongName(var p : String) : boolean;
|
|||||||
|
|
||||||
{Environment}
|
{Environment}
|
||||||
Function EnvCount: longint;
|
Function EnvCount: longint;
|
||||||
Function EnvStr(index: integer): string;
|
Function EnvStr (Index: longint): string;
|
||||||
Function GetEnv(envvar: string): string;
|
Function GetEnv(envvar: string): string;
|
||||||
|
|
||||||
{Misc}
|
{Misc}
|
||||||
|
@ -134,7 +134,11 @@ End;
|
|||||||
--- Exec ---
|
--- Exec ---
|
||||||
******************************************************************************}
|
******************************************************************************}
|
||||||
|
|
||||||
|
{$ifdef HASTHREADVAR}
|
||||||
|
threadvar
|
||||||
|
{$else HASTHREADVAR}
|
||||||
var
|
var
|
||||||
|
{$endif HASTHREADVAR}
|
||||||
lastdosexitcode : word;
|
lastdosexitcode : word;
|
||||||
|
|
||||||
procedure exec(const path : pathstr;const comline : comstr);
|
procedure exec(const path : pathstr;const comline : comstr);
|
||||||
@ -691,7 +695,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function envstr(index : integer) : string;
|
function envstr (index: longint) : string;
|
||||||
begin
|
begin
|
||||||
envstr := ''; {is there a netware function to do that ?????}
|
envstr := ''; {is there a netware function to do that ?????}
|
||||||
ConsolePrintf ('warning: fpc dos.envstr not implemented'#13#10,0);
|
ConsolePrintf ('warning: fpc dos.envstr not implemented'#13#10,0);
|
||||||
@ -746,7 +750,10 @@ end;
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.7 2004-02-09 12:03:16 michael
|
Revision 1.8 2004-02-15 21:34:06 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.7 2004/02/09 12:03:16 michael
|
||||||
+ Switched to single interface in dosh.inc
|
+ Switched to single interface in dosh.inc
|
||||||
|
|
||||||
Revision 1.6 2003/03/25 18:17:54 armin
|
Revision 1.6 2003/03/25 18:17:54 armin
|
||||||
|
@ -509,6 +509,26 @@ begin
|
|||||||
Result := DosExitCode;
|
Result := DosExitCode;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
function ExecuteProcess (const Path: AnsiString;
|
||||||
|
const ComLine: array of AnsiString): integer;
|
||||||
|
|
||||||
|
var
|
||||||
|
CommandLine: AnsiString;
|
||||||
|
I: integer;
|
||||||
|
|
||||||
|
begin
|
||||||
|
Commandline := '';
|
||||||
|
for I := 0 to High (ComLine) do
|
||||||
|
if Pos (' ', ComLine [I]) <> 0 then
|
||||||
|
CommandLine := CommandLine + ' ' + '"' + ComLine [I] + '"'
|
||||||
|
else
|
||||||
|
CommandLine := CommandLine + ' ' + Comline [I];
|
||||||
|
ExecuteProcess := ExecuteProcess (Path, CommandLine);
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{****************************************************************************
|
{****************************************************************************
|
||||||
Initialization code
|
Initialization code
|
||||||
****************************************************************************}
|
****************************************************************************}
|
||||||
@ -522,7 +542,10 @@ end.
|
|||||||
{
|
{
|
||||||
|
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.14 2004-01-20 23:11:20 hajny
|
Revision 1.15 2004-02-15 21:34:06 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.14 2004/01/20 23:11:20 hajny
|
||||||
* ExecuteProcess fixes, ProcessID and ThreadID added
|
* ExecuteProcess fixes, ProcessID and ThreadID added
|
||||||
|
|
||||||
Revision 1.13 2003/11/26 20:00:19 florian
|
Revision 1.13 2003/11/26 20:00:19 florian
|
||||||
|
@ -93,10 +93,7 @@ const
|
|||||||
(* For compatibility with VP/2, used for runflags in Exec procedure. *)
|
(* For compatibility with VP/2, used for runflags in Exec procedure. *)
|
||||||
ExecFlags: cardinal = ord (efwait);
|
ExecFlags: cardinal = ord (efwait);
|
||||||
|
|
||||||
var
|
{$i dosh.inc}
|
||||||
dosexitcodevar:word;
|
|
||||||
|
|
||||||
{$I dosh.inc}
|
|
||||||
|
|
||||||
{OS/2 specific functions}
|
{OS/2 specific functions}
|
||||||
|
|
||||||
@ -160,14 +157,21 @@ begin
|
|||||||
DosError := integer (RC);
|
DosError := integer (RC);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure exec(const path:pathstr;const comline:comstr);
|
{$ifdef HASTHREADVAR}
|
||||||
|
threadvar
|
||||||
|
{$else HASTHREADVAR}
|
||||||
|
var
|
||||||
|
{$endif HASTHREADVAR}
|
||||||
|
LastDosExitCode: longint;
|
||||||
|
|
||||||
|
procedure exec (const path:pathstr;const comline:comstr);
|
||||||
{Execute a program.}
|
{Execute a program.}
|
||||||
begin
|
begin
|
||||||
dosexitcodevar:=word(exec(path,execrunflags(ExecFlags),efdefault,comline));
|
LastDosExitCode := Exec (Path, ExecRunFlags (ExecFlags), efDefault, ComLine);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function exec(path:pathstr;runflags:execrunflags;winflags:execwinflags;
|
function Exec (path:pathstr;runflags:execrunflags;winflags:execwinflags;
|
||||||
const comline:comstr):longint;
|
const comline:comstr): longint;
|
||||||
{Execute a program. More suitable for OS/2 than the exec above.}
|
{Execute a program. More suitable for OS/2 than the exec above.}
|
||||||
var args:Pbytearray;
|
var args:Pbytearray;
|
||||||
env:Pbytearray;
|
env:Pbytearray;
|
||||||
@ -257,6 +261,13 @@ begin
|
|||||||
a system function I ever wrote!}
|
a system function I ever wrote!}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
function DosExitCode: word;
|
||||||
|
begin
|
||||||
|
DosExitCode := LastDosExitCode and $FFFF;
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
function dosversion:word;
|
function dosversion:word;
|
||||||
{Returns OS/2 version}
|
{Returns OS/2 version}
|
||||||
var
|
var
|
||||||
@ -425,7 +436,7 @@ begin
|
|||||||
envcount:=envc;
|
envcount:=envc;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function envstr(index : integer) : string;
|
function envstr (index : longint) : string;
|
||||||
|
|
||||||
var hp:Pchar;
|
var hp:Pchar;
|
||||||
|
|
||||||
@ -628,31 +639,33 @@ begin
|
|||||||
DosError := integer (RC);
|
DosError := integer (RC);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function DosExitCode: word;
|
|
||||||
begin
|
|
||||||
DosExitCode:=dosexitcodevar;
|
|
||||||
end;
|
|
||||||
|
|
||||||
Procedure Intr(intno: byte; var regs: registers);
|
|
||||||
|
{******************************************************************************
|
||||||
|
--- Not Supported ---
|
||||||
|
******************************************************************************}
|
||||||
|
|
||||||
|
procedure Keep (ExitCode: word);
|
||||||
begin
|
begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
Procedure MSDos(var regs: registers);
|
procedure GetIntVec (IntNo: byte; var Vector: pointer);
|
||||||
begin
|
begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
Procedure GetIntVec(intno: byte; var vector: pointer);
|
procedure SetIntVec (IntNo: byte; Vector: pointer);
|
||||||
begin
|
begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
Procedure SetIntVec(intno: byte; vector: pointer);
|
procedure Intr (IntNo: byte; var Regs: Registers);
|
||||||
begin
|
begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
Procedure Keep(exitcode: word);
|
procedure MsDos (var Regs: Registers);
|
||||||
begin
|
begin
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function GetShortName(var p : String) : boolean;
|
function GetShortName(var p : String) : boolean;
|
||||||
begin
|
begin
|
||||||
GetShortName:=true;
|
GetShortName:=true;
|
||||||
@ -661,12 +674,20 @@ end;
|
|||||||
function GetLongName(var p : String) : boolean;
|
function GetLongName(var p : String) : boolean;
|
||||||
begin
|
begin
|
||||||
GetLongName:=true;
|
GetLongName:=true;
|
||||||
|
{$WARNING EA .longname support should be probably added here}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
begin
|
||||||
|
LastDosExitCode := 0;
|
||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.35 2004-02-15 08:02:44 yuri
|
Revision 1.36 2004-02-15 21:34:06 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.35 2004/02/15 08:02:44 yuri
|
||||||
* fixes for dosh.inc
|
* fixes for dosh.inc
|
||||||
* Executeprocess iverloaded function
|
* Executeprocess iverloaded function
|
||||||
* updated todo
|
* updated todo
|
||||||
|
@ -944,18 +944,25 @@ begin
|
|||||||
raise E;
|
raise E;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function ExecuteProcess(Const Path: AnsiString; Const ComLine: Array of AnsiString):integer;
|
|
||||||
|
|
||||||
Var
|
function ExecuteProcess (const Path: AnsiString;
|
||||||
CommandLine : AnsiString;
|
const ComLine: array of AnsiString): integer;
|
||||||
i : Integer;
|
|
||||||
|
var
|
||||||
|
CommandLine: AnsiString;
|
||||||
|
I: integer;
|
||||||
|
|
||||||
|
begin
|
||||||
|
Commandline := '';
|
||||||
|
for I := 0 to High (ComLine) do
|
||||||
|
if Pos (' ', ComLine [I]) <> 0 then
|
||||||
|
CommandLine := CommandLine + ' ' + '"' + ComLine [I] + '"'
|
||||||
|
else
|
||||||
|
CommandLine := CommandLine + ' ' + Comline [I];
|
||||||
|
ExecuteProcess := ExecuteProcess (Path, CommandLine);
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
Begin
|
|
||||||
Commandline:='';
|
|
||||||
For i:=0 to high(ComLine) Do
|
|
||||||
Commandline:=CommandLine+' '+Comline[i];
|
|
||||||
ExecuteProcess:=ExecuteProcess(Path,CommandLine);
|
|
||||||
End;
|
|
||||||
|
|
||||||
{****************************************************************************
|
{****************************************************************************
|
||||||
Initialization code
|
Initialization code
|
||||||
@ -970,7 +977,10 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.41 2004-02-15 08:02:44 yuri
|
Revision 1.42 2004-02-15 21:36:10 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.41 2004/02/15 08:02:44 yuri
|
||||||
* fixes for dosh.inc
|
* fixes for dosh.inc
|
||||||
* Executeprocess iverloaded function
|
* Executeprocess iverloaded function
|
||||||
* updated todo
|
* updated todo
|
||||||
|
@ -271,6 +271,26 @@ begin
|
|||||||
Result := DosExitCode;
|
Result := DosExitCode;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
function ExecuteProcess (const Path: AnsiString;
|
||||||
|
const ComLine: array of AnsiString): integer;
|
||||||
|
|
||||||
|
var
|
||||||
|
CommandLine: AnsiString;
|
||||||
|
I: integer;
|
||||||
|
|
||||||
|
begin
|
||||||
|
Commandline := '';
|
||||||
|
for I := 0 to High (ComLine) do
|
||||||
|
if Pos (' ', ComLine [I]) <> 0 then
|
||||||
|
CommandLine := CommandLine + ' ' + '"' + ComLine [I] + '"'
|
||||||
|
else
|
||||||
|
CommandLine := CommandLine + ' ' + Comline [I];
|
||||||
|
ExecuteProcess := ExecuteProcess (Path, CommandLine);
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{****************************************************************************
|
{****************************************************************************
|
||||||
Initialization code
|
Initialization code
|
||||||
****************************************************************************}
|
****************************************************************************}
|
||||||
@ -284,7 +304,10 @@ Finalization
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.4 2004-01-20 23:12:49 hajny
|
Revision 1.5 2004-02-15 21:36:10 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.4 2004/01/20 23:12:49 hajny
|
||||||
* ExecuteProcess fixes, ProcessID and ThreadID added
|
* ExecuteProcess fixes, ProcessID and ThreadID added
|
||||||
|
|
||||||
Revision 1.3 2003/03/29 15:16:26 hajny
|
Revision 1.3 2003/03/29 15:16:26 hajny
|
||||||
|
@ -223,7 +223,11 @@ End;
|
|||||||
--- Exec ---
|
--- Exec ---
|
||||||
******************************************************************************}
|
******************************************************************************}
|
||||||
|
|
||||||
|
{$ifdef HASTHREADVAR}
|
||||||
|
threadvar
|
||||||
|
{$else HASTHREADVAR}
|
||||||
var
|
var
|
||||||
|
{$endif HASTHREADVAR}
|
||||||
LastDosExitCode: word;
|
LastDosExitCode: word;
|
||||||
|
|
||||||
Procedure Exec (Const Path: PathStr; Const ComLine: ComStr);
|
Procedure Exec (Const Path: PathStr; Const ComLine: ComStr);
|
||||||
@ -683,7 +687,7 @@ End;
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
Function EnvStr(Index: Integer): String;
|
Function EnvStr (Index: longint): String;
|
||||||
Var
|
Var
|
||||||
i : longint;
|
i : longint;
|
||||||
p : ppchar;
|
p : ppchar;
|
||||||
@ -824,7 +828,10 @@ End.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.25 2004-02-09 17:01:28 marco
|
Revision 1.26 2004-02-15 21:36:10 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.25 2004/02/09 17:01:28 marco
|
||||||
* fixes to get it working under FreeBSD, and probably Linux too
|
* fixes to get it working under FreeBSD, and probably Linux too
|
||||||
|
|
||||||
Revision 1.24 2004/02/09 12:03:16 michael
|
Revision 1.24 2004/02/09 12:03:16 michael
|
||||||
|
@ -167,7 +167,11 @@ End;
|
|||||||
--- Exec ---
|
--- Exec ---
|
||||||
******************************************************************************}
|
******************************************************************************}
|
||||||
|
|
||||||
|
{$ifdef HASTHREADVAR}
|
||||||
|
threadvar
|
||||||
|
{$else HASTHREADVAR}
|
||||||
var
|
var
|
||||||
|
{$endif HASTHREADVAR}
|
||||||
lastdosexitcode : word;
|
lastdosexitcode : word;
|
||||||
|
|
||||||
procedure exec(const path : pathstr;const comline : comstr);
|
procedure exec(const path : pathstr;const comline : comstr);
|
||||||
@ -892,7 +896,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function envstr(index : integer) : string;
|
function EnvStr (Index: longint): string;
|
||||||
begin
|
begin
|
||||||
if (index<=0) or (index>envcount) then
|
if (index<=0) or (index>envcount) then
|
||||||
begin
|
begin
|
||||||
@ -947,7 +951,10 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.5 2004-02-09 12:03:16 michael
|
Revision 1.6 2004-02-15 21:36:10 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.5 2004/02/09 12:03:16 michael
|
||||||
+ Switched to single interface in dosh.inc
|
+ Switched to single interface in dosh.inc
|
||||||
|
|
||||||
Revision 1.4 2003/10/18 09:18:29 hajny
|
Revision 1.4 2003/10/18 09:18:29 hajny
|
||||||
|
@ -782,6 +782,26 @@ begin
|
|||||||
Result := DosExitCode;
|
Result := DosExitCode;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
function ExecuteProcess (const Path: AnsiString;
|
||||||
|
const ComLine: array of AnsiString): integer;
|
||||||
|
|
||||||
|
var
|
||||||
|
CommandLine: AnsiString;
|
||||||
|
I: integer;
|
||||||
|
|
||||||
|
begin
|
||||||
|
Commandline := '';
|
||||||
|
for I := 0 to High (ComLine) do
|
||||||
|
if Pos (' ', ComLine [I]) <> 0 then
|
||||||
|
CommandLine := CommandLine + ' ' + '"' + ComLine [I] + '"'
|
||||||
|
else
|
||||||
|
CommandLine := CommandLine + ' ' + Comline [I];
|
||||||
|
ExecuteProcess := ExecuteProcess (Path, CommandLine);
|
||||||
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
{*************************************************************************
|
{*************************************************************************
|
||||||
Sleep (copied from crt.Delay)
|
Sleep (copied from crt.Delay)
|
||||||
*************************************************************************}
|
*************************************************************************}
|
||||||
@ -861,7 +881,10 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.4 2004-01-20 23:12:49 hajny
|
Revision 1.5 2004-02-15 21:36:10 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.4 2004/01/20 23:12:49 hajny
|
||||||
* ExecuteProcess fixes, ProcessID and ThreadID added
|
* ExecuteProcess fixes, ProcessID and ThreadID added
|
||||||
|
|
||||||
Revision 1.3 2003/12/15 15:57:49 peter
|
Revision 1.3 2003/12/15 15:57:49 peter
|
||||||
|
@ -309,7 +309,11 @@ type
|
|||||||
function CloseHandle(h : TWin32Handle) : longint;
|
function CloseHandle(h : TWin32Handle) : longint;
|
||||||
stdcall; external 'kernel32' name 'CloseHandle';
|
stdcall; external 'kernel32' name 'CloseHandle';
|
||||||
|
|
||||||
|
{$ifdef HASTHREADVAR}
|
||||||
|
threadvar
|
||||||
|
{$else HASTHREADVAR}
|
||||||
var
|
var
|
||||||
|
{$endif HASTHREADVAR}
|
||||||
lastdosexitcode : longint;
|
lastdosexitcode : longint;
|
||||||
|
|
||||||
procedure exec(const path : pathstr;const comline : comstr);
|
procedure exec(const path : pathstr;const comline : comstr);
|
||||||
@ -851,7 +855,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
Function EnvStr(index: integer): string;
|
Function EnvStr (Index: longint): string;
|
||||||
var
|
var
|
||||||
hp,p : pchar;
|
hp,p : pchar;
|
||||||
count,i : longint;
|
count,i : longint;
|
||||||
@ -956,7 +960,10 @@ begin
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.23 2004-02-09 12:03:16 michael
|
Revision 1.24 2004-02-15 21:36:10 hajny
|
||||||
|
* overloaded ExecuteProcess added, EnvStr param changed to longint
|
||||||
|
|
||||||
|
Revision 1.23 2004/02/09 12:03:16 michael
|
||||||
+ Switched to single interface in dosh.inc
|
+ Switched to single interface in dosh.inc
|
||||||
|
|
||||||
Revision 1.22 2004/01/06 00:58:35 florian
|
Revision 1.22 2004/01/06 00:58:35 florian
|
||||||
|
Loading…
Reference in New Issue
Block a user