From 216f905670ecf67f735ae591607d88bc4fea037a Mon Sep 17 00:00:00 2001 From: Gabi Melman Date: Fri, 20 Sep 2019 16:11:22 +0300 Subject: [PATCH] Fix log msg buffer operator= --- include/spdlog/details/log_msg_buffer-inl.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/spdlog/details/log_msg_buffer-inl.h b/include/spdlog/details/log_msg_buffer-inl.h index df38aef9..8ad05050 100644 --- a/include/spdlog/details/log_msg_buffer-inl.h +++ b/include/spdlog/details/log_msg_buffer-inl.h @@ -36,6 +36,7 @@ namespace details { SPDLOG_INLINE log_msg_buffer &log_msg_buffer::operator=(const log_msg_buffer &other) { log_msg::operator=(other); + buffe.clear(); buffer.append(other.buffer.data(), other.buffer.data() + other.buffer.size()); update_string_views(); return *this;