mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-13 09:39:09 +02:00
* GetCurrentThreadHandle renamed to GetCurrentThreadId
This commit is contained in:
parent
6f6630bd46
commit
39add9f5ff
@ -52,7 +52,7 @@ function KillThread (threadHandle : dword) : dword;
|
|||||||
function WaitForThreadTerminate (threadHandle : dword; TimeoutMs : longint) : dword; {0=no timeout}
|
function WaitForThreadTerminate (threadHandle : dword; TimeoutMs : longint) : dword; {0=no timeout}
|
||||||
function ThreadSetPriority (threadHandle : dword; Prio: longint): boolean; {-15..+15, 0=normal}
|
function ThreadSetPriority (threadHandle : dword; Prio: longint): boolean; {-15..+15, 0=normal}
|
||||||
function ThreadGetPriority (threadHandle : dword): Integer;
|
function ThreadGetPriority (threadHandle : dword): Integer;
|
||||||
function GetCurrentThreadHandle : dword;
|
function GetCurrentThreadId : dword;
|
||||||
|
|
||||||
|
|
||||||
{ this allows to do a lot of things in MT safe way }
|
{ this allows to do a lot of things in MT safe way }
|
||||||
@ -65,7 +65,10 @@ procedure LeaveCriticalsection(var cs : TRTLCriticalSection);
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.10 2003-03-27 17:14:27 armin
|
Revision 1.11 2003-10-01 21:00:09 peter
|
||||||
|
* GetCurrentThreadHandle renamed to GetCurrentThreadId
|
||||||
|
|
||||||
|
Revision 1.10 2003/03/27 17:14:27 armin
|
||||||
* more platform independent thread routines, needs to be implemented for unix
|
* more platform independent thread routines, needs to be implemented for unix
|
||||||
|
|
||||||
Revision 1.9 2002/10/16 19:04:27 michael
|
Revision 1.9 2002/10/16 19:04:27 michael
|
||||||
|
@ -269,9 +269,9 @@ end;
|
|||||||
|
|
||||||
function GetThreadID : dword; cdecl; external 'clib' name 'GetThreadID';
|
function GetThreadID : dword; cdecl; external 'clib' name 'GetThreadID';
|
||||||
|
|
||||||
function GetCurrentThreadHandle : dword;
|
function GetCurrentThreadId : dword;
|
||||||
begin
|
begin
|
||||||
GetCurrentThreadHandle := GetThreadID;
|
GetCurrentThreadId := GetThreadID;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
@ -454,7 +454,10 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.2 2003-03-27 17:14:27 armin
|
Revision 1.3 2003-10-01 21:00:09 peter
|
||||||
|
* GetCurrentThreadHandle renamed to GetCurrentThreadId
|
||||||
|
|
||||||
|
Revision 1.2 2003/03/27 17:14:27 armin
|
||||||
* more platform independent thread routines, needs to be implemented for unix
|
* more platform independent thread routines, needs to be implemented for unix
|
||||||
|
|
||||||
Revision 1.1 2003/02/16 17:12:15 armin
|
Revision 1.1 2003/02/16 17:12:15 armin
|
||||||
|
@ -302,9 +302,9 @@ CONST
|
|||||||
{$Warning ThreadGetPriority needs to be implemented}
|
{$Warning ThreadGetPriority needs to be implemented}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function GetCurrentThreadHandle : dword;
|
function GetCurrentThreadId : dword;
|
||||||
begin
|
begin
|
||||||
GetCurrentThreadHandle:=dword(pthread_self);
|
GetCurrentThreadId:=dword(pthread_self);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
@ -385,7 +385,10 @@ initialization
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.14 2003-10-01 20:53:08 peter
|
Revision 1.15 2003-10-01 21:00:09 peter
|
||||||
|
* GetCurrentThreadHandle renamed to GetCurrentThreadId
|
||||||
|
|
||||||
|
Revision 1.14 2003/10/01 20:53:08 peter
|
||||||
* GetCurrentThreadId implemented
|
* GetCurrentThreadId implemented
|
||||||
|
|
||||||
Revision 1.13 2003/09/20 12:38:29 marco
|
Revision 1.13 2003/09/20 12:38:29 marco
|
||||||
|
@ -81,7 +81,7 @@ function GetLastError : dword; stdcall;external 'kernel32' name 'GetLastError';
|
|||||||
function WaitForSingleObject (hHandle,Milliseconds: dword): dword; stdcall;external 'kernel32' name 'WaitForSingleObject';
|
function WaitForSingleObject (hHandle,Milliseconds: dword): dword; stdcall;external 'kernel32' name 'WaitForSingleObject';
|
||||||
function WinThreadSetPriority (threadHandle : dword; Prio: longint): boolean; stdcall;external 'kernel32' name 'SetThreadPriority';
|
function WinThreadSetPriority (threadHandle : dword; Prio: longint): boolean; stdcall;external 'kernel32' name 'SetThreadPriority';
|
||||||
function WinThreadGetPriority (threadHandle : dword): Integer; stdcall;external 'kernel32' name 'GetThreadPriority';
|
function WinThreadGetPriority (threadHandle : dword): Integer; stdcall;external 'kernel32' name 'GetThreadPriority';
|
||||||
function WinGetCurrentThreadHandle : dword; stdcall;external 'kernel32' name 'GetCurrentThread';
|
function WinGetCurrentThreadId : dword; stdcall;external 'kernel32' name 'GetCurrentThread';
|
||||||
|
|
||||||
{*****************************************************************************
|
{*****************************************************************************
|
||||||
Threadvar support
|
Threadvar support
|
||||||
@ -264,9 +264,9 @@ function WinGetCurrentThreadHandle : dword; stdcall;external 'kernel32' name 'G
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function GetCurrentThreadHandle : dword;
|
function GetCurrentThreadId : dword;
|
||||||
begin
|
begin
|
||||||
GetCurrentThreadHandle:=WinGetCurrentThreadHandle;
|
GetCurrentThreadId:=WinGetCurrentThreadId;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{*****************************************************************************
|
{*****************************************************************************
|
||||||
@ -355,7 +355,10 @@ initialization
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.5 2003-09-17 15:06:36 peter
|
Revision 1.6 2003-10-01 21:00:09 peter
|
||||||
|
* GetCurrentThreadHandle renamed to GetCurrentThreadId
|
||||||
|
|
||||||
|
Revision 1.5 2003/09/17 15:06:36 peter
|
||||||
* stdcall patch
|
* stdcall patch
|
||||||
|
|
||||||
Revision 1.4 2003/03/27 17:14:27 armin
|
Revision 1.4 2003/03/27 17:14:27 armin
|
||||||
|
Loading…
Reference in New Issue
Block a user