unsigned initflag,
unsigned* thrdaddr)
{
+ HANDLE NewThread;
+
+ /*
+ * Just call the API function. Any CRT specific processing is done in
+ * DllMain DLL_THREAD_ATTACH
+ */
+ NewThread = CreateThread(security, stack_size, start_address, arglist, initflag, thrdaddr);
+ if (NULL == NewThread)
+ {
+ /* FIXME map GetLastError() to errno */
errno = ENOSYS;
- return (unsigned long)-1;
+ }
+
+ return (unsigned long) NewThread;
}
void _endthreadex(unsigned retval)
{
+ /*
+ * Just call the API function. Any CRT specific processing is done in
+ * DllMain DLL_THREAD_DETACH
+ */
+ ExitThread(retval);
}
/* EOF */