diff --git a/src/common/model/source_file.h b/src/common/model/source_file.h index 5117be49..f56c1f39 100644 --- a/src/common/model/source_file.h +++ b/src/common/model/source_file.h @@ -92,7 +92,8 @@ public: { LOG_DBG("Adding source file: {}, {}", f->name(), f->full_name(true)); - add_element(f->path(), std::move(f)); + const auto path = f->path(); + add_element(path, std::move(f)); } std::filesystem::path fs_path(const std::filesystem::path &base = {}) const