Skip to content
This repository was archived by the owner on Jul 4, 2025. It is now read-only.

Commit e286092

Browse files
authored
Merge pull request #1844 from janhq/fix/use-after-move
fix: use after std::move
2 parents 7918935 + 9b96b47 commit e286092

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

engine/services/engine_service.cc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -763,8 +763,8 @@ cpp::result<void, std::string> EngineService::LoadEngine(
763763
// register deps
764764
if (!(getenv("ENGINE_PATH"))) {
765765
std::vector<std::filesystem::path> paths{};
766-
paths.push_back(std::move(cuda_path));
767-
paths.push_back(std::move(engine_dir_path));
766+
paths.push_back(cuda_path);
767+
paths.push_back(engine_dir_path);
768768

769769
CTL_DBG("Registering dylib for "
770770
<< ne << " with " << std::to_string(paths.size()) << " paths.");
@@ -830,8 +830,8 @@ void EngineService::RegisterEngineLibPath() {
830830

831831
// register deps
832832
std::vector<std::filesystem::path> paths{};
833-
paths.push_back(std::move(cuda_path));
834-
paths.push_back(std::move(engine_dir_path));
833+
paths.push_back(cuda_path);
834+
paths.push_back(engine_dir_path);
835835

836836
CTL_DBG("Registering dylib for "
837837
<< ne << " with " << std::to_string(paths.size()) << " paths.");

0 commit comments

Comments
 (0)