From 89fba5c8473b8f8b2133698f1e1b9b14535c0bc0 Mon Sep 17 00:00:00 2001 From: regnat Date: Mon, 26 Jul 2021 11:34:47 +0200 Subject: [PATCH] Use the real path when checking imported CA paths Otherwise chrooted store will fail because Nix will try to read the virtual path instead of the physical one Should fix https://github.com/NixOS/nixpkgs/issues/126141 --- src/libstore/local-store.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libstore/local-store.cc b/src/libstore/local-store.cc index 5b62d79ee..31a6cc46f 100644 --- a/src/libstore/local-store.cc +++ b/src/libstore/local-store.cc @@ -1038,7 +1038,7 @@ void LocalStore::addToStore(const ValidPathInfo & info, Source & source, auto actualFoHash = hashCAPath( recursive, expectedHash.type, - info.path + realPath ); if (ca != actualFoHash) { throw Error("ca hash mismatch importing path '%s';\n specified: %s\n got: %s",