diff --git a/include/spdlog/details/thread_pool.h b/include/spdlog/details/thread_pool.h index 9107cd1b..2d5cb060 100644 --- a/include/spdlog/details/thread_pool.h +++ b/include/spdlog/details/thread_pool.h @@ -75,13 +75,13 @@ struct async_msg , time(m.time) , thread_id(m.thread_id) , msg_id(m.msg_id) - , worker_ptr(std::forward(worker)) + , worker_ptr(std::move(worker)) { fmt_helper::append_buf(m.raw, raw); } async_msg(async_logger_ptr &&worker, async_msg_type the_type) - : async_msg(std::forward(worker), the_type, details::log_msg()) + : async_msg(std::move(worker), the_type, details::log_msg()) { } @@ -151,7 +151,7 @@ public: void post_log(async_logger_ptr &&worker_ptr, details::log_msg &&msg, async_overflow_policy overflow_policy) { - async_msg async_m(std::forward(worker_ptr), async_msg_type::log, std::forward(msg)); + async_msg async_m(std::move(worker_ptr), async_msg_type::log, std::forward(msg)); post_async_msg_(std::move(async_m), overflow_policy); }