mirror of
https://github.com/NixOS/nix
synced 2025-06-27 00:11:17 +02:00
* Replace read-only calls to addTextToStore.
This commit is contained in:
parent
a824d58b56
commit
fcd9900d74
2 changed files with 9 additions and 3 deletions
|
@ -389,7 +389,9 @@ static Expr primToFile(EvalState & state, const ATermVector & args)
|
|||
refs.insert(*i);
|
||||
}
|
||||
|
||||
Path storePath = store->addTextToStore(name, contents, refs);
|
||||
Path storePath = readOnlyMode
|
||||
? computeStorePathForText(name, contents)
|
||||
: store->addTextToStore(name, contents, refs);
|
||||
|
||||
/* Note: we don't need to add `context' to the context of the
|
||||
result, since `storePath' itself has references to the paths
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue