1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-30 15:48:00 +02:00

Make the store directory a member variable of Store

This commit is contained in:
Eelco Dolstra 2016-06-01 14:49:12 +02:00
parent 1b5b654fe2
commit 7850d3d279
35 changed files with 315 additions and 296 deletions

View file

@ -387,7 +387,7 @@ static void queryInstSources(EvalState & state,
case srcStorePaths: {
for (auto & i : args) {
Path path = followLinksToStorePath(i);
Path path = state.store->followLinksToStorePath(i);
string name = baseNameOf(path);
string::size_type dash = name.find('-');
@ -742,7 +742,7 @@ static void uninstallDerivations(Globals & globals, Strings & selectors,
for (auto & j : selectors)
/* !!! the repeated calls to followLinksToStorePath()
are expensive, should pre-compute them. */
if ((isPath(j) && i.queryOutPath() == followLinksToStorePath(j))
if ((isPath(j) && i.queryOutPath() == globals.state->store->followLinksToStorePath(j))
|| DrvName(j).matches(drvName))
{
printMsg(lvlInfo, format("uninstalling %1%") % i.name);