diff --git a/include/spdlog/async_logger.h b/include/spdlog/async_logger.h index 70ee3267..932d7fb3 100644 --- a/include/spdlog/async_logger.h +++ b/include/spdlog/async_logger.h @@ -61,7 +61,7 @@ protected: void sink_it_(details::log_msg &msg) override; void flush_() override; - void backend_log_(details::log_msg &incoming_log_msg); + void backend_log_(const details::log_msg &incoming_log_msg); void backend_flush_(); private: diff --git a/include/spdlog/details/async_logger_impl.h b/include/spdlog/details/async_logger_impl.h index 3ad70a3b..55df4313 100644 --- a/include/spdlog/details/async_logger_impl.h +++ b/include/spdlog/details/async_logger_impl.h @@ -67,7 +67,7 @@ inline void spdlog::async_logger::flush_() // // backend functions - called from the thread pool to do the actual job // -inline void spdlog::async_logger::backend_log_(details::log_msg &incoming_log_msg) +inline void spdlog::async_logger::backend_log_(const details::log_msg &incoming_log_msg) { try {