From a3a8f107a468a16ae31b2a2c85c1489e0273c854 Mon Sep 17 00:00:00 2001 From: gabime Date: Fri, 21 Nov 2014 00:46:57 +0200 Subject: [PATCH] revert syslog --- include/spdlog/sinks/syslog_sink.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/include/spdlog/sinks/syslog_sink.h b/include/spdlog/sinks/syslog_sink.h index c70b6dc2..1d7c28d0 100644 --- a/include/spdlog/sinks/syslog_sink.h +++ b/include/spdlog/sinks/syslog_sink.h @@ -65,11 +65,9 @@ namespace spdlog syslog_sink(const syslog_sink&) = delete; syslog_sink& operator=(const syslog_sink&) = delete; - void sink_it(const char* data, size_t size) override + void log(const details::log_msg &msg) override { - std::string s(data, size); - //syslog(syslog_prio_from_level(msg), "%s", s.c_str()); - syslog(LOG_INFO, "%s", s.c_str()); + syslog(syslog_prio_from_level(msg), "%s", msg.formatted.str().c_str()); }; protected: