Fix wrong thread_id (TID) in systemd_sink.h (#2919)

This commit is contained in:
M010 2023-10-24 01:43:47 +03:00 committed by GitHub
parent 2d5179ba7d
commit 8b331e2cd1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -70,7 +70,7 @@ protected:
err = (sd_journal_send)("MESSAGE=%.*s", static_cast<int>(length), payload.data(), err = (sd_journal_send)("MESSAGE=%.*s", static_cast<int>(length), payload.data(),
"PRIORITY=%d", syslog_level(msg.level), "PRIORITY=%d", syslog_level(msg.level),
#ifndef SPDLOG_NO_THREAD_ID #ifndef SPDLOG_NO_THREAD_ID
"TID=%zu", details::os::thread_id(), "TID=%zu", msg.thread_id,
#endif #endif
"SYSLOG_IDENTIFIER=%.*s", "SYSLOG_IDENTIFIER=%.*s",
static_cast<int>(syslog_identifier.size()), static_cast<int>(syslog_identifier.size()),
@ -79,7 +79,7 @@ protected:
err = (sd_journal_send)("MESSAGE=%.*s", static_cast<int>(length), payload.data(), err = (sd_journal_send)("MESSAGE=%.*s", static_cast<int>(length), payload.data(),
"PRIORITY=%d", syslog_level(msg.level), "PRIORITY=%d", syslog_level(msg.level),
#ifndef SPDLOG_NO_THREAD_ID #ifndef SPDLOG_NO_THREAD_ID
"TID=%zu", details::os::thread_id(), "TID=%zu", msg.thread_id,
#endif #endif
"SYSLOG_IDENTIFIER=%.*s", "SYSLOG_IDENTIFIER=%.*s",
static_cast<int>(syslog_identifier.size()), static_cast<int>(syslog_identifier.size()),