Explorar el Código

+ WebAssembly threads: initialize the ThreadId threadvar for the main thread

Nikolay Nikolov hace 1 año
padre
commit
02867fe918
Se han modificado 1 ficheros con 1 adiciones y 0 borrados
  1. 1 0
      rtl/wasi/systhrd.inc

+ 1 - 0
rtl/wasi/systhrd.inc

@@ -132,6 +132,7 @@ begin
   GlobalIsMainThread:=1;
   GlobalIsWorkerThread:=0;
   GlobalCurrentThread:=@MainThread;
+  ThreadId:=@MainThread;
 {$IFDEF FPC_WASM_MAIN_THREAD_CAN_WAIT}
   GlobalIsThreadBlockable:=1;
 {$ELSE FPC_WASM_MAIN_THREAD_CAN_WAIT}