瀏覽代碼

+ WASI: set StackBottom on startup

Nikolay Nikolov 1 年之前
父節點
當前提交
68f4191119
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      rtl/wasi/system.pp

+ 1 - 0
rtl/wasi/system.pp

@@ -431,6 +431,7 @@ end;
 
 begin
   StackLength:=CheckInitialStkLen(stklen);
+  StackBottom:=Pointer(PtrUInt(InitialHeapBlockStart)-PtrUInt(StackLength));
   { To be set if this is a GUI or console application }
   IsConsole := TRUE;
 {$ifdef FPC_HAS_FEATURE_DYNLIBS}