diff --git a/frameworks/libhilog/base/hilog_base.c b/frameworks/libhilog/base/hilog_base.c index c482e9c9bf495559d40d5d3051ea9fcc297fb83e..5a2835308df9d82862bdfa526f2ce50accacb8bb 100644 --- a/frameworks/libhilog/base/hilog_base.c +++ b/frameworks/libhilog/base/hilog_base.c @@ -25,6 +25,8 @@ #include #include #include +#include +#include #define LOG_LEN 3 #define ERROR_FD 2 @@ -76,6 +78,10 @@ static int SendMessage(HilogMsg *header, const char *tag, uint16_t tagLen, const return ret; } +pid_t gettid(void) { + return (pid_t)syscall(SYS_gettid); +} + int HiLogBasePrintArgs( const LogType type, const LogLevel level, const unsigned int domain, const char *tag, const char *fmt, va_list ap) {