1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-27 21:01:16 +02:00

Merge pull request #3899 from obsidiansystems/make-narHash-not-optional

Make narHash in ValidPathInfo not optional
This commit is contained in:
Eelco Dolstra 2020-08-14 17:00:18 +02:00 committed by GitHub
commit d81f13f7cb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
24 changed files with 145 additions and 118 deletions

View file

@ -212,7 +212,7 @@ static void fetch(EvalState & state, const Pos & pos, Value * * args, Value & v,
: hashFile(htSHA256, path);
if (hash != *expectedHash)
throw Error((unsigned int) 102, "hash mismatch in file downloaded from '%s':\n wanted: %s\n got: %s",
*url, expectedHash->to_string(Base32, true), hash->to_string(Base32, true));
*url, expectedHash->to_string(Base32, true), hash.to_string(Base32, true));
}
if (state.allowedPaths)