diff options
author | Matthew Bauer <mjbauer95@gmail.com> | 2020-06-12 14:57:45 -0500 |
---|---|---|
committer | Matthew Bauer <mjbauer95@gmail.com> | 2020-06-12 14:57:45 -0500 |
commit | 5b386b05f58b1ed996afe47791d85e6d20da91a2 (patch) | |
tree | b7082a2b2b4984c334be763e35f52bbcbdaaff3a | |
parent | 85d01e1f658d93a0ea8d0396b1e79d03c2ff1da2 (diff) |
Recompute storePath based on isContentAddressed
-rw-r--r-- | src/libstore/store-api.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstore/store-api.cc b/src/libstore/store-api.cc index afa557e16..c8dc4744f 100644 --- a/src/libstore/store-api.cc +++ b/src/libstore/store-api.cc @@ -581,7 +581,7 @@ void copyStorePath(ref<Store> srcStore, ref<Store> dstStore, uint64_t total = 0; // recompute store path on the chance dstStore does it differently - if (hasPrefix(info->ca, "fixed:") && info->references.empty()) { + if (info->isContentAddressed(*srcStore)) { auto info2 = make_ref<ValidPathInfo>(*info); FileIngestionMethod ingestionMethod { info->ca.compare(6, 2, "r:") == 0 }; Hash hash(std::string(info->ca, ingestionMethod == FileIngestionMethod::Recursive ? 8 : 6)); |