diff --git a/libraries/libldap_r/thr_posix.c b/libraries/libldap_r/thr_posix.c index 825761e330..ed0c9425b8 100644 --- a/libraries/libldap_r/thr_posix.c +++ b/libraries/libldap_r/thr_posix.c @@ -121,7 +121,12 @@ ldap_pvt_thread_create( ldap_pvt_thread_t * thread, pthread_attr_setdetachstate(&attr, detach); #endif #endif + +#if HAVE_PTHREADS < 5 + rtn = pthread_create( thread, attr, start_routine, arg ); +#else rtn = pthread_create( thread, &attr, start_routine, arg ); +#endif #if HAVE_PTHREADS > 5 pthread_attr_destroy(&attr); #else