Преглед на файлове

* CheckInitialStkLen and/or StackLength initialization added to previously omitted targets

git-svn-id: trunk@1736 -
Tomas Hajny преди 19 години
родител
ревизия
f29fde8978
променени са 5 файла, в които са добавени 19 реда и са изтрити 0 реда
  1. 5 0
      rtl/atari/system.pas
  2. 1 0
      rtl/beos/system.pp
  3. 6 0
      rtl/emx/system.pas
  4. 6 0
      rtl/os2/system.pas
  5. 1 0
      rtl/palmos/system.pp

+ 5 - 0
rtl/atari/system.pas

@@ -747,8 +747,13 @@ end;
                          SystemUnit Initialization
                          SystemUnit Initialization
 *****************************************************************************}
 *****************************************************************************}
 
 
+function CheckInitialStkLen (StkLen: SizeUInt): SizeUInt;
+begin
+  CheckInitialStkLen := StkLen;
+end;
 
 
 begin
 begin
+  StackLength := CheckInitialStkLen (InitialStkLen);
 { Initialize ExitProc }
 { Initialize ExitProc }
   ExitProc:=Nil;
   ExitProc:=Nil;
 { Setup heap }
 { Setup heap }

+ 1 - 0
rtl/beos/system.pp

@@ -531,6 +531,7 @@ begin
   myheaprealsize:=$2000;
   myheaprealsize:=$2000;
   myheapstart:=nil;
   myheapstart:=nil;
   heap_handle:=sys_create_area('fpcheap',myheapstart,0,myheaprealsize,0,3);//!!
   heap_handle:=sys_create_area('fpcheap',myheapstart,0,myheaprealsize,0,3);//!!
+  StackLength := CheckInitialStkLen (InitialStkLen);
   if heap_handle>0 then begin
   if heap_handle>0 then begin
     InitHeap;
     InitHeap;
   end else system_exit;
   end else system_exit;

+ 6 - 0
rtl/emx/system.pas

@@ -445,6 +445,11 @@ begin
                                                  else GetFileHandleCount := L2;
                                                  else GetFileHandleCount := L2;
 end;
 end;
 
 
+function CheckInitialStkLen (StkLen: SizeUInt): SizeUInt;
+begin
+  CheckInitialStkLen := StkLen;
+end;
+
 var TIB: PThreadInfoBlock;
 var TIB: PThreadInfoBlock;
     PIB: PProcessInfoBlock;
     PIB: PProcessInfoBlock;
 
 
@@ -558,6 +563,7 @@ begin
             end;
             end;
     end;
     end;
     exitproc:=nil;
     exitproc:=nil;
+    StackLength := CheckInitialStkLen (InitialStkLen);
 
 
     {Initialize the heap.}
     {Initialize the heap.}
     initheap;
     initheap;

+ 6 - 0
rtl/os2/system.pas

@@ -694,6 +694,11 @@ begin
                                                  else GetFileHandleCount := L2;
                                                  else GetFileHandleCount := L2;
 end;
 end;
 
 
+function CheckInitialStkLen (StkLen: SizeUInt): SizeUInt;
+begin
+  CheckInitialStkLen := StkLen;
+end;
+
 var TIB: PThreadInfoBlock;
 var TIB: PThreadInfoBlock;
     RC: cardinal;
     RC: cardinal;
     ErrStr: string;
     ErrStr: string;
@@ -707,6 +712,7 @@ begin
     DosGetInfoBlocks (@TIB, @PIB);
     DosGetInfoBlocks (@TIB, @PIB);
     StackBottom := TIB^.Stack;
     StackBottom := TIB^.Stack;
     StackTop := PtrUInt (TIB^.StackLimit);
     StackTop := PtrUInt (TIB^.StackLimit);
+    StackLength := CheckInitialStkLen (InitialStkLen);
 
 
     {Set type of application}
     {Set type of application}
     ApplicationType := PIB^.ProcType;
     ApplicationType := PIB^.ProcType;

+ 1 - 0
rtl/palmos/system.pp

@@ -110,5 +110,6 @@ begin
 end;
 end;
 
 
 begin
 begin
+   StackLength := CheckInitialStkLen (InitialStkLen);
    ExitCode:=0;
    ExitCode:=0;
 end.
 end.