From f0c35819bd6604980e58dbf2ec5dee239b232675 Mon Sep 17 00:00:00 2001 From: gabime Date: Sun, 22 Mar 2020 02:17:48 +0200 Subject: [PATCH] Removed unneeded nullptr check --- include/spdlog/details/fmt_helper.h | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/include/spdlog/details/fmt_helper.h b/include/spdlog/details/fmt_helper.h index 85b988e6..183690d2 100644 --- a/include/spdlog/details/fmt_helper.h +++ b/include/spdlog/details/fmt_helper.h @@ -20,10 +20,7 @@ inline spdlog::string_view_t to_string_view(const memory_buf_t &buf) SPDLOG_NOEX inline void append_string_view(spdlog::string_view_t view, memory_buf_t &dest) { auto *buf_ptr = view.data(); - if (buf_ptr != nullptr) - { - dest.append(buf_ptr, buf_ptr + view.size()); - } + dest.append(buf_ptr, buf_ptr + view.size()); } template