From 9fbf82b603fd2394737b73a0a6b59d7a8f18bd76 Mon Sep 17 00:00:00 2001 From: gabime Date: Mon, 15 Jul 2019 01:31:31 +0300 Subject: [PATCH] Fixed gcc9 conversion warning --- include/spdlog/sinks/syslog_sink.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/spdlog/sinks/syslog_sink.h b/include/spdlog/sinks/syslog_sink.h index 8546915c..43ffef6b 100644 --- a/include/spdlog/sinks/syslog_sink.h +++ b/include/spdlog/sinks/syslog_sink.h @@ -61,9 +61,9 @@ protected: size_t length = payload.size(); // limit to max int - if (length > std::numeric_limits::max()) + if (length > static_cast(std::numeric_limits::max())) { - length = std::numeric_limits::max(); + length = static_cast(std::numeric_limits::max()); } ::syslog(syslog_prio_from_level(msg), "%.*s", static_cast(length), payload.data());