Import thread fix

This commit is contained in:
Kurt Zeilenga 2001-05-06 21:52:58 +00:00
parent 9c2b5515df
commit a2f1c95d40

View File

@ -35,9 +35,16 @@ ldap_pvt_thread_create( ldap_pvt_thread_t * thread,
void *(*start_routine)( void *), void *(*start_routine)( void *),
void *arg) void *arg)
{ {
*thread = (ldap_pvt_thread_t)_beginthread( (void *) start_routine, unsigned long tid
0, arg ); HANDLE thd;
return ( (unsigned long)*thread == -1 ? -1 : 0 );
thd = _beginthreadex( NULL, 0,
(LPTHREAD_START_ROUTINE) start_routine, arg,
0, &tid );
*thread = (ldap_pvt_thread_t) thd;
return thd == NULL ? -1 : 0;
} }
void void