From 1e4a61ce63347212bc41c5a91554e97a4cc97bd1 Mon Sep 17 00:00:00 2001 From: kssenii Date: Tue, 27 Apr 2021 20:22:39 +0300 Subject: [PATCH] Fix build --- src/Storages/Distributed/DirectoryMonitor.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/Storages/Distributed/DirectoryMonitor.cpp b/src/Storages/Distributed/DirectoryMonitor.cpp index ac376f92e73..7381468a399 100644 --- a/src/Storages/Distributed/DirectoryMonitor.cpp +++ b/src/Storages/Distributed/DirectoryMonitor.cpp @@ -479,11 +479,10 @@ std::map StorageDistributedDirectoryMonitor::getFiles() for (fs::directory_iterator it{path}; it != end; ++it) { const auto & file_path_str = it->path(); - fs::path fs_file_path(file_path_str); - if (!it->is_directory() && startsWith(fs_file_path.extension(), ".bin")) + if (!it->is_directory() && startsWith(fs::path(file_path_str).extension(), ".bin")) { - files[parse(fs_file_path.stem())] = file_path_str; - new_bytes_count += fs::file_size(fs_file_path); + files[parse(fs::path(file_path_str).stem())] = file_path_str; + new_bytes_count += fs::file_size(fs::path(file_path_str)); } }