diff options
author | Eelco Dolstra <e.dolstra@tudelft.nl> | 2006-12-05 02:18:46 +0000 |
---|---|---|
committer | Eelco Dolstra <e.dolstra@tudelft.nl> | 2006-12-05 02:18:46 +0000 |
commit | a9c4f66cfb1618833cc70ceaf13733730b634193 (patch) | |
tree | 47d3b9aab72f561e2e15f18b8ad415153bfd56ef /src/nix-store | |
parent | 29cf434a35d82529f56c085c9cd50858c148d086 (diff) | |
download | guix-a9c4f66cfb1618833cc70ceaf13733730b634193.tar.gz |
* Allow unprivileged users to run the garbage collector and to do
`nix-store --delete'. But unprivileged users are not allowed to ignore liveness. * `nix-store --delete --ignore-liveness': ignore the runtime roots as well.
Diffstat (limited to 'src/nix-store')
-rw-r--r-- | src/nix-store/main.cc | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/nix-store/main.cc b/src/nix-store/main.cc index eb037bda19..701e839742 100644 --- a/src/nix-store/main.cc +++ b/src/nix-store/main.cc @@ -3,7 +3,6 @@ #include "globals.hh" #include "misc.hh" -#include "gc.hh" #include "archive.hh" #include "shared.hh" #include "dotgraph.hh" @@ -573,7 +572,7 @@ static void opGC(Strings opFlags, Strings opArgs) PathSet result; PrintFreed freed(action == gcDeleteDead || action == gcReturnDead, action == gcReturnDead); - collectGarbage(action, PathSet(), false, result, freed.bytesFreed); + store->collectGarbage(action, PathSet(), false, result, freed.bytesFreed); if (action != gcDeleteDead) { for (PathSet::iterator i = result.begin(); i != result.end(); ++i) @@ -601,7 +600,7 @@ static void opDelete(Strings opFlags, Strings opArgs) PathSet dummy; PrintFreed freed(true, false); - collectGarbage(gcDeleteSpecific, pathsToDelete, ignoreLiveness, + store->collectGarbage(gcDeleteSpecific, pathsToDelete, ignoreLiveness, dummy, freed.bytesFreed); } |