FS-10167 complile issues for mac sierra
This commit is contained in:
parent
f0afe29c9c
commit
5003c66406
|
@ -73,6 +73,10 @@
|
|||
|
||||
#endif /* WIN32 */
|
||||
|
||||
#ifndef SOL_IPV6
|
||||
#define SOL_IPV6 41
|
||||
#endif
|
||||
|
||||
#ifdef KS_USE_POLL
|
||||
#include <poll.h>
|
||||
#endif
|
||||
|
|
|
@ -46,7 +46,8 @@ KS_DECLARE(ks_pid_t) ks_thread_self_id(void)
|
|||
#elif gettid
|
||||
return gettid();
|
||||
#else
|
||||
return syscall(SYS_gettid);
|
||||
return (ks_pid_t) pthread_self();
|
||||
//return syscall(SYS_gettid);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
|
@ -243,7 +243,7 @@ KS_DECLARE(void) ks_sleep(ks_time_t microsec)
|
|||
clock_nanosleep(CLOCK_MONOTONIC, 0, &ts, NULL);
|
||||
#elif defined(__APPLE__)
|
||||
ts.tv_sec = ks_time_sec(microsec);
|
||||
ts.tv_nsec = ks_time_usec(microsec) * 850;
|
||||
ts.tv_nsec = ks_time_usec(microsec) * 900;
|
||||
nanosleep(&ts, NULL);
|
||||
#else
|
||||
generic_sleep(microsec);
|
||||
|
|
Loading…
Reference in New Issue