Sfoglia il codice sorgente

Merged revisions 1637 via svnmerge from
http://[email protected]/svn/fpc/trunk

r1637 (tom_at_work)
* added stacksize parameter for TThread.Create for some platforms left out in commit 1621

git-svn-id: branches/fixes_2_0@1672 -

Tomas Hajny 20 anni fa
parent
commit
a65f76cefe
2 ha cambiato i file con 3 aggiunte e 3 eliminazioni
  1. 1 1
      rtl/go32v2/tthread.inc
  2. 2 2
      rtl/openbsd/tthread.inc

+ 1 - 1
rtl/go32v2/tthread.inc

@@ -46,7 +46,7 @@ begin
 end;
 
 
-constructor TThread.Create(CreateSuspended: Boolean);
+constructor TThread.Create(CreateSuspended: Boolean; const StackSize: DWord = DefaultStackSize);
 
 begin
  {IsMultiThread := TRUE; }

+ 2 - 2
rtl/openbsd/tthread.inc

@@ -186,7 +186,7 @@ begin
 end;
 
 { TThread }
-constructor TThread.Create(CreateSuspended: Boolean);
+constructor TThread.Create(CreateSuspended: Boolean; const StackSize: DWord = DefaultStackSize);
 begin
   // lets just hope that the user doesn't create a thread
   // via BeginThread and creates the first TThread Object in there!
@@ -198,7 +198,7 @@ begin
   FInitialSuspended := CreateSuspended;
   FFatalException := nil;
   WRITE_DEBUG('creating thread, self = ',longint(self));
-  FHandle:= BeginThread(@ThreadFunc, Pointer(Self), FThreadID);
+  FHandle:= BeginThread(@ThreadFunc, Pointer(Self), FThreadID, StackSize);
   WRITE_DEBUG('TThread.Create done');
 end;