diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2015-03-25T16·06+0100 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2015-03-25T16·06+0100 |
commit | 7ea6ecf855dee69a1cd938c3fe7e4e132be00b24 (patch) | |
tree | 0607f4f32d9c764f7df324e81e733ca84c991936 /src/libexpr | |
parent | 5114a07d9578e06c66862270a3d624fc0944f33a (diff) |
addToStore(): Take explicit name argument
Diffstat (limited to 'src/libexpr')
-rw-r--r-- | src/libexpr/eval.cc | 2 | ||||
-rw-r--r-- | src/libexpr/primops.cc | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/libexpr/eval.cc b/src/libexpr/eval.cc index db135844e5b7..d8a4193a8e64 100644 --- a/src/libexpr/eval.cc +++ b/src/libexpr/eval.cc @@ -1419,7 +1419,7 @@ string EvalState::copyPathToStore(PathSet & context, const Path & path) else { dstPath = settings.readOnlyMode ? computeStorePathForPath(checkSourcePath(path)).first - : store->addToStore(checkSourcePath(path), true, htSHA256, defaultPathFilter, repair); + : store->addToStore(baseNameOf(path), checkSourcePath(path), true, htSHA256, defaultPathFilter, repair); srcToStore[path] = dstPath; printMsg(lvlChatty, format("copied source ‘%1%’ -> ‘%2%’") % path % dstPath); diff --git a/src/libexpr/primops.cc b/src/libexpr/primops.cc index 9723cdfd247b..ac7652d37806 100644 --- a/src/libexpr/primops.cc +++ b/src/libexpr/primops.cc @@ -943,7 +943,7 @@ static void prim_filterSource(EvalState & state, const Pos & pos, Value * * args Path dstPath = settings.readOnlyMode ? computeStorePathForPath(path, true, htSHA256, filter).first - : store->addToStore(path, true, htSHA256, filter, state.repair); + : store->addToStore(baseNameOf(path), path, true, htSHA256, filter, state.repair); mkString(v, dstPath, singleton<PathSet>(dstPath)); } |