Commit 2a0cb937 authored by Michael Lee's avatar Michael Lee Committed by facebook-github-bot-1

Change `SYS_gettid` to __NR_gettid instead

Summary: SYS_gettid is not available on all platforms, but __NR_gettid should be.

Reviewed By: dcolascione

Differential Revision: D2787003

fb-gh-sync-id: ee024437ac95281a3573e2440653847f6f7d1738
parent 015ca678
......@@ -38,7 +38,7 @@ pid_t localThreadId() {
// OSX doesn't support thread_local.
static FOLLY_TLS pid_t threadId = 0;
if (UNLIKELY(threadId == 0)) {
threadId = syscall(SYS_gettid);
threadId = syscall(__NR_gettid);
}
return threadId;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment