去除了 vthreading 的 c.Addr

This commit is contained in:
TermiNexus committed 2026-09-29 16:47:50 +08:00
1 parent 9cef4d8b56
commit 4fed54aa8b
1 file changed
+2 -3
+2 -3
View File
@@ -1,4 +1,3 @@
import t, c
from stdint import *
from w32.win32base import *
from w32.win32process import CreateThread, GetExitCodeThread, GetCurrentThreadId, TlsAlloc, TlsFree, TlsGetValue, TlsSetValue
@@ -43,7 +42,7 @@ class Thread:
def start(self):
if self.started:
return
self.handle = CreateThread(NULL, 0, self.target, self.arg, 0, c.Addr(self.thread_id))
self.handle = CreateThread(NULL, 0, self.target, self.arg, 0, &self.thread_id)
self.started = TRUE
def join(self, timeout_ms: ULONG = INFINITE) -> BOOL:
@@ -60,7 +59,7 @@ class Thread:
def get_exit_code(self) -> ULONG:
code: ULONG = 0
GetExitCodeThread(self.handle, c.Addr(code))
GetExitCodeThread(self.handle, &code)
return code
def close(self):