fix build error
Some checks failed
linux-x64-gcc / linux-gcc (push) Successful in 43s
rpcrypto-build / build (Release, himix200.toolchain.cmake) (push) Successful in 57s
rpcrypto-build / build (Debug, himix200.toolchain.cmake) (push) Successful in 1m2s
linux-mips64-gcc / linux-gcc-mips64el (push) Successful in 1m59s
rpcrypto-build / build (Debug, hisiv510.toolchain.cmake) (push) Successful in 1m0s
linux-hisiv500-gcc / linux-gcc-hisiv500 (push) Failing after 20m48s
rpcrypto-build / build (Release, hisiv510.toolchain.cmake) (push) Failing after 20m27s

This commit is contained in:
tqcq 2023-12-27 11:35:46 +08:00
parent 44f0021d30
commit 58f7e4e7e1
2 changed files with 1 additions and 6 deletions

View File

@ -8,6 +8,7 @@
#include "ulib/base/location.h" #include "ulib/base/location.h"
#include "logger.h" #include "logger.h"
#include "level.h" #include "level.h"
#include <stdlib.h>
#include <fmt/format.h> #include <fmt/format.h>
namespace tqcq { namespace tqcq {

View File

@ -13,13 +13,7 @@ pid_t
GetTid() GetTid()
{ {
// TODO cache tid // TODO cache tid
#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_12
uint64_t tid64;
pthread_threadid_np(NULL, &tid64);
return static_cast<pid_t>(tid64);
#else
return static_cast<pid_t>(::syscall(SYS_gettid)); return static_cast<pid_t>(::syscall(SYS_gettid));
#endif
} }
class Thread::Impl { class Thread::Impl {