summaryrefslogtreecommitdiff
path: root/src/other_tools/root_maps/content_git_map.cpp
diff options
context:
space:
mode:
authorPaul Cristian Sarbu <paul.cristian.sarbu@huawei.com>2024-01-30 17:50:03 +0100
committerPaul Cristian Sarbu <paul.cristian.sarbu@huawei.com>2024-02-16 17:22:22 +0100
commitcfa8c2a41e8a585834e4d04d56ff7eec0d57f608 (patch)
treecb13964c7b39af02baedc1a52c4d1a21f56a63d9 /src/other_tools/root_maps/content_git_map.cpp
parentaa16dd1b3a50aa402003bc80fa0145d1a845c2cb (diff)
downloadjustbuild-cfa8c2a41e8a585834e4d04d56ff7eec0d57f608.tar.gz
async maps: Create utility library to handle cycle detection
Diffstat (limited to 'src/other_tools/root_maps/content_git_map.cpp')
-rw-r--r--src/other_tools/root_maps/content_git_map.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/other_tools/root_maps/content_git_map.cpp b/src/other_tools/root_maps/content_git_map.cpp
index 5d910015..0a70cb0c 100644
--- a/src/other_tools/root_maps/content_git_map.cpp
+++ b/src/other_tools/root_maps/content_git_map.cpp
@@ -18,6 +18,7 @@
#include "src/buildtool/file_system/file_root.hpp"
#include "src/buildtool/file_system/file_storage.hpp"
#include "src/buildtool/file_system/symlinks_map/pragma_special.hpp"
+#include "src/buildtool/multithreading/async_map_utils.hpp"
#include "src/buildtool/multithreading/task_system.hpp"
#include "src/buildtool/serve_api/remote/serve_api.hpp"
#include "src/buildtool/storage/config.hpp"
@@ -206,9 +207,10 @@ void ResolveContentTree(
logger](auto const& hashes) {
if (not hashes[0]) {
// check for cycles
- auto error = DetectAndReportCycle(*resolve_symlinks_map,
- tree_hash);
- if (error) {
+ if (auto error = DetectAndReportCycle(
+ fmt::format("resolving Git tree {}", tree_hash),
+ *resolve_symlinks_map,
+ kGitObjectToResolvePrinter)) {
(*logger)(fmt::format("Failed to resolve symlinks "
"in tree {}:\n{}",
tree_hash,