Skip to content

Commit

Permalink
*: fix gettid compile error (#4704)
Browse files Browse the repository at this point in the history
close #4703
  • Loading branch information
ywqzzy authored Apr 19, 2022
1 parent feee96a commit 636fcd2
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions dbms/src/Storages/BackgroundProcessingPool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@
#ifdef __linux__
#include <sys/syscall.h>
#include <unistd.h>
inline static pid_t gettid()
inline static pid_t getTid()
{
return syscall(SYS_gettid);
}
#elif
inline static pid_t gettid()
#else
inline static pid_t getTid()
{
return -1;
}
Expand Down Expand Up @@ -150,7 +150,7 @@ void BackgroundProcessingPool::threadFunction()
const auto name = "BkgPool" + std::to_string(tid++);
setThreadName(name.data());
is_background_thread = true;
addThreadId(gettid());
addThreadId(getTid());
}

MemoryTracker memory_tracker;
Expand Down

0 comments on commit 636fcd2

Please sign in to comment.