Fix error in thread creation function on Windows

This commit is contained in:
2024-06-16 12:25:16 +03:00
parent ecab74bb22
commit d8b9e97e07

View File

@@ -46,7 +46,7 @@ int bh_thread_init_base(bh_thread_t *thread,
/* Create and setup thread (relative to the callers libc) */ /* Create and setup thread (relative to the callers libc) */
thread->allocated = 0; thread->allocated = 0;
thread->handle = (HANDLE)_beginthreadex(NULL, 0, bh_thread_run, data, 0, NULL); thread->handle = (HANDLE)begin(NULL, 0, bh_thread_run, data, 0, NULL);
/* Check for errors */ /* Check for errors */
if (!thread->handle) if (!thread->handle)