diff options
author | Maksim Denisov <denisov.maksim@huawei.com> | 2025-04-22 11:09:17 +0200 |
---|---|---|
committer | Maksim Denisov <denisov.maksim@huawei.com> | 2025-04-22 13:50:57 +0200 |
commit | a212d87be891c5146021b6442063ed39a4a1cd4a (patch) | |
tree | 9df2902cf7f8bf9d70917ab87865517e9bdc71c3 /src/other_tools/ops_maps | |
parent | ba51f59519847a3d298fd176d93a0b6c64f452c1 (diff) | |
download | justbuild-a212d87be891c5146021b6442063ed39a4a1cd4a.tar.gz |
Remove redundant calls to std::filesystem::absolute
...when calling std::filesystem::weakly_canonical, since the latter converts the argument path to an absolute path internally.
Diffstat (limited to 'src/other_tools/ops_maps')
-rw-r--r-- | src/other_tools/ops_maps/critical_git_op_map.hpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/other_tools/ops_maps/critical_git_op_map.hpp b/src/other_tools/ops_maps/critical_git_op_map.hpp index 3e5a07ee..1494e3b3 100644 --- a/src/other_tools/ops_maps/critical_git_op_map.hpp +++ b/src/other_tools/ops_maps/critical_git_op_map.hpp @@ -74,8 +74,8 @@ class CriticalGitOpGuard { std::scoped_lock<std::mutex> const lock(critical_key_mutex_); // try emplace a new value - auto const canonical_path = std::filesystem::weakly_canonical( - std::filesystem::absolute(new_key.params.target_path)); + auto const canonical_path = + std::filesystem::weakly_canonical(new_key.params.target_path); auto result = curr_critical_key_.try_emplace(canonical_path, new_key); // If the insertion happens, there are no keys to wait for. std::nullopt // is returned. |