From 2a0cb93725b4adae2b3fa901aa0ff6107786bd06 Mon Sep 17 00:00:00 2001 From: Michael Lee Date: Wed, 23 Dec 2015 12:38:29 -0800 Subject: [PATCH] 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 --- folly/experimental/fibers/Fiber.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/folly/experimental/fibers/Fiber.cpp b/folly/experimental/fibers/Fiber.cpp index b4fea854..9721e903 100644 --- a/folly/experimental/fibers/Fiber.cpp +++ b/folly/experimental/fibers/Fiber.cpp @@ -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; } -- 2.34.1