diff --git a/include/spdlog/sinks/systemd_sink.h b/include/spdlog/sinks/systemd_sink.h index e449a1ae9..c79c4339a 100644 --- a/include/spdlog/sinks/systemd_sink.h +++ b/include/spdlog/sinks/systemd_sink.h @@ -70,7 +70,7 @@ class systemd_sink : public base_sink { err = (sd_journal_send)("MESSAGE=%.*s", static_cast(length), payload.data(), "PRIORITY=%d", syslog_level(msg.log_level), #ifndef SPDLOG_NO_THREAD_ID - "TID=%zu", details::os::thread_id(), + "TID=%zu", msg.thread_id, #endif "SYSLOG_IDENTIFIER=%.*s", static_cast(syslog_identifier.size()), @@ -79,7 +79,7 @@ class systemd_sink : public base_sink { err = (sd_journal_send)("MESSAGE=%.*s", static_cast(length), payload.data(), "PRIORITY=%d", syslog_level(msg.log_level), #ifndef SPDLOG_NO_THREAD_ID - "TID=%zu", details::os::thread_id(), + "TID=%zu", msg.thread_id, #endif "SYSLOG_IDENTIFIER=%.*s", static_cast(syslog_identifier.size()),