From 7c5318a46e33db98d6a6882d372da00afd6ac403 Mon Sep 17 00:00:00 2001 From: Michael Lee Date: Mon, 2 May 2016 16:14:23 -0700 Subject: [PATCH] Use portability for SYS_gettid Summary: It's there for a reason, so use it. Reviewed By: yfeldblum Differential Revision: D3249849 fb-gh-sync-id: e9fe330693a173acd987e0c8fd1f03a982c8e082 fbshipit-source-id: e9fe330693a173acd987e0c8fd1f03a982c8e082 --- folly/io/async/test/TimeUtil.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/folly/io/async/test/TimeUtil.cpp b/folly/io/async/test/TimeUtil.cpp index de9f325b..558aa22a 100644 --- a/folly/io/async/test/TimeUtil.cpp +++ b/folly/io/async/test/TimeUtil.cpp @@ -13,11 +13,14 @@ * See the License for the specific language governing permissions and * limitations under the License. */ +#ifndef __STDC_FORMAT_MACROS #define __STDC_FORMAT_MACROS +#endif #include #include +#include #include #include @@ -40,7 +43,7 @@ namespace folly { * glibc doesn't provide gettid(), so define it ourselves. */ static pid_t gettid() { - return syscall(SYS_gettid); + return syscall(FOLLY_SYS_gettid); } /** -- 2.34.1