summaryrefslogtreecommitdiff
path: root/src/buildtool/serve_api/serve_service/source_tree.cpp
diff options
context:
space:
mode:
authorMaksim Denisov <denisov.maksim@huawei.com>2024-07-05 16:49:45 +0200
committerMaksim Denisov <denisov.maksim@huawei.com>2024-07-22 17:01:13 +0200
commitbeb3faa6956b9bfd58d4ea6644a9b2987409aaba (patch)
tree9a1edee40bfe335717eb856237372d50127367ac /src/buildtool/serve_api/serve_service/source_tree.cpp
parent30f2b4a215ebd4f9c0c491f41de6e8eb56ed3fdf (diff)
downloadjustbuild-beb3faa6956b9bfd58d4ea6644a9b2987409aaba.tar.gz
Use HashFunction functionality via Instance()
...to track changes during refactoring easier.
Diffstat (limited to 'src/buildtool/serve_api/serve_service/source_tree.cpp')
-rw-r--r--src/buildtool/serve_api/serve_service/source_tree.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/buildtool/serve_api/serve_service/source_tree.cpp b/src/buildtool/serve_api/serve_service/source_tree.cpp
index 29e9ade2..f86fdb45 100644
--- a/src/buildtool/serve_api/serve_service/source_tree.cpp
+++ b/src/buildtool/serve_api/serve_service/source_tree.cpp
@@ -25,6 +25,7 @@
#include "src/buildtool/common/artifact_digest.hpp"
#include "src/buildtool/compatibility/compatibility.hpp"
#include "src/buildtool/compatibility/native_support.hpp"
+#include "src/buildtool/crypto/hash_function.hpp"
#include "src/buildtool/execution_api/git/git_api.hpp"
#include "src/buildtool/file_system/file_system_manager.hpp"
#include "src/buildtool/file_system/git_repo.hpp"
@@ -1158,9 +1159,9 @@ auto SourceTreeService::ServeDistdirTree(
kv.name(), std::make_pair(blob_digest, kv.executable()));
}
// get hash of distdir content; this must match with that in just-mr
- auto content_id =
- HashFunction::ComputeBlobHash(nlohmann::json(content_list).dump())
- .HexString();
+ auto content_id = HashFunction::Instance()
+ .ComputeBlobHash(nlohmann::json(content_list).dump())
+ .HexString();
// create in-memory tree of the distdir, now that we know we have all blobs
auto tree = GitRepo::CreateShallowTree(entries);
if (not tree) {