From 4fca1b96730814666a1823f595dba5912a272d43 Mon Sep 17 00:00:00 2001 From: xiaobfly <313060639@qq.com> Date: Thu, 1 Apr 2021 17:21:19 +0800 Subject: [PATCH] fixed filename extension --- src/logging.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/logging.cc b/src/logging.cc index 56f02c030..25614b613 100644 --- a/src/logging.cc +++ b/src/logging.cc @@ -997,10 +997,11 @@ void LogFileObject::FlushUnlocked(){ } bool LogFileObject::CreateLogfile(const string& time_pid_string) { - string string_filename = base_filename_+filename_extension_; + string string_filename = base_filename_; if (FLAGS_timestamp_in_logfile_name) { string_filename += time_pid_string; } + string_filename += filename_extension_; const char* filename = string_filename.c_str(); //only write to files, create if non-existant. int flags = O_WRONLY | O_CREAT;