mirror of
https://github.com/NixOS/nix.git
synced 2024-11-25 16:23:02 +00:00
fixup: Compute fingerprint only if needed
This commit is contained in:
parent
1c4e392c64
commit
19cc50dcbf
@ -464,10 +464,10 @@ ref<eval_cache::EvalCache> openEvalCache(
|
|||||||
return aOutputs->value;
|
return aOutputs->value;
|
||||||
};
|
};
|
||||||
|
|
||||||
if (hash) {
|
if (fingerprint) {
|
||||||
auto search = state.evalCaches.find(hash.value());
|
auto search = state.evalCaches.find(fingerprint.value());
|
||||||
if (search == state.evalCaches.end()) {
|
if (search == state.evalCaches.end()) {
|
||||||
search = state.evalCaches.emplace(hash.value(), make_ref<nix::eval_cache::EvalCache>(hash, state, rootLoader)).first;
|
search = state.evalCaches.emplace(fingerprint.value(), make_ref<nix::eval_cache::EvalCache>(fingerprint, state, rootLoader)).first;
|
||||||
}
|
}
|
||||||
return search->second;
|
return search->second;
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user