DWORD WINAPI __win32thread_launcher(LPVOID lpParameter) { Thread* t; t = (Thread*) lpParameter; t->SetSchedulingPriority(); t->LockMemory(); t->EnableDestructor(); t->Main(); return 0; }
/// Callback function for the POSIX thread API static void* __pthread_launcher(void* thread) { pthread_setcanceltype(PTHREAD_CANCEL_ASYNCHRONOUS, NULL); // let the thread be killable under any circumstances Thread* t; t = (Thread*) thread; t->SetSchedulingPriority(); t->LockMemory(); t->EnableDestructor(); t->Main(); return NULL; }