fix tid/handle bug on macos/win

This commit is contained in:
PePerRoNii
2025-07-22 11:00:49 +07:00
parent a357113651
commit 3c9d05a8c6
2 changed files with 4 additions and 2 deletions

View File

@@ -223,7 +223,9 @@ _set_name :: proc(thread: ^Thread) {
return
}
tid := thread.unix_thread
when ODIN_OS != .Darwin {
tid := thread.unix_thread
}
buf: [_MAX_PTHREAD_NAME_LENGTH]u8
copy(buf[:], name)

View File

@@ -179,7 +179,7 @@ _set_name :: proc(thread: ^Thread) {
return
}
t_handle = thread.win32_thread
t_handle := thread.win32_thread
buf: [_THREAD_DESCRIPTION_LENGTH]u16
// _THREAD_DESCRIPTION_LENGTH includes terminating null