diff options
author | Maksim Denisov <denisov.maksim@huawei.com> | 2024-09-12 12:24:59 +0200 |
---|---|---|
committer | Maksim Denisov <denisov.maksim@huawei.com> | 2024-09-13 14:41:00 +0200 |
commit | 4f7d0c2af84d25a8b8b7a5c0ad7b58d94b4c8f7c (patch) | |
tree | 0127ed3b1a2421852e04c99b05cba53796a81f30 /src/buildtool/execution_engine/executor/executor.hpp | |
parent | add0ff5993a261f72aabf461a32314e11fea90ba (diff) | |
download | justbuild-4f7d0c2af84d25a8b8b7a5c0ad7b58d94b4c8f7c.tar.gz |
Check compatibility in Executor based on the hash type
Diffstat (limited to 'src/buildtool/execution_engine/executor/executor.hpp')
-rw-r--r-- | src/buildtool/execution_engine/executor/executor.hpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/buildtool/execution_engine/executor/executor.hpp b/src/buildtool/execution_engine/executor/executor.hpp index 5a1eb857..4b2548da 100644 --- a/src/buildtool/execution_engine/executor/executor.hpp +++ b/src/buildtool/execution_engine/executor/executor.hpp @@ -213,6 +213,7 @@ class ExecutorImpl { } if (not VerifyOrUploadKnownArtifact( + apis.hash_function.GetType(), *apis.remote, artifact->Content().Repository(), repo_config, @@ -433,11 +434,12 @@ class ExecutorImpl { /// \param info The info of the object /// \returns true on success [[nodiscard]] static auto VerifyOrUploadKnownArtifact( + HashFunction::Type hash_type, IExecutionApi const& api, std::string const& repo, gsl::not_null<const RepositoryConfig*> const& repo_config, Artifact::ObjectInfo const& info) noexcept -> bool { - if (ProtocolTraits::Instance().IsCompatible()) { + if (not ProtocolTraits::IsNative(hash_type)) { auto opt = GitHashesConverter::Instance().GetGitEntry(info.digest.hash()); if (opt) { |