async_sink to use queue of pointers of log_msgs - faster than moving..

This commit is contained in:
gabime 2014-11-17 01:12:50 +02:00
parent fe25056b38
commit 91fae223cc

View File

@ -115,9 +115,7 @@ inline void spdlog::sinks::async_sink::_sink_it(const details::log_msg& msg)
{ {
using namespace spdlog::details; using namespace spdlog::details;
_push_sentry(); _push_sentry();
//_q.push(std::move(msg)); _q.push(std::unique_ptr<log_msg>(new log_msg(msg)));
auto msg_p = std::unique_ptr<log_msg>(new log_msg(msg));
_q.push(std::move(msg_p));
} }