From ec356ef7b15213eb3ebd36248676cac4e44dc273 Mon Sep 17 00:00:00 2001 From: MistEO Date: Sun, 4 Sep 2022 23:53:16 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E4=BC=98=E5=8C=96Logger=E5=B0=8F?= =?UTF-8?q?=E7=BB=86=E8=8A=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/MeoAssistant/Logger.hpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/MeoAssistant/Logger.hpp b/src/MeoAssistant/Logger.hpp index c9b6502a12..9a5b6eae83 100644 --- a/src/MeoAssistant/Logger.hpp +++ b/src/MeoAssistant/Logger.hpp @@ -26,8 +26,6 @@ namespace asst return false; } m_directory = dir; - m_log_path = m_directory / "asst.log"; - m_log_bak_path = m_directory / "asst.bak.log"; return true; } @@ -234,9 +232,9 @@ namespace asst } inline static std::filesystem::path m_directory; - inline static std::filesystem::path m_log_path; - inline static std::filesystem::path m_log_bak_path; + std::filesystem::path m_log_path = m_directory / "asst.log"; + std::filesystem::path m_log_bak_path = m_directory / "asst.bak.log"; std::mutex m_trace_mutex; std::ofstream m_ofs; };