about summary refs log tree commit diff
path: root/src/nix/command.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2016-11-10T16·45+0100
committerEelco Dolstra <edolstra@gmail.com>2016-11-10T16·45+0100
commitdd77f7d5931e500585b6539b52ef5a5f3b549a4e (patch)
tree8df85662ed52e49bb0669f5e5c86ef3105163d45 /src/nix/command.cc
parent2af5d35fdc1171a9bdab7e2fc005673d76417c06 (diff)
Store::computeFSClosure(): Support a set of paths
This way, callers can exploits the parallelism of computeFSClosure()
when they have multiple paths that they need the (combined) closure of.
Diffstat (limited to 'src/nix/command.cc')
-rw-r--r--src/nix/command.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nix/command.cc b/src/nix/command.cc
index fdf6ae6affaf..5a8288da912f 100644
--- a/src/nix/command.cc
+++ b/src/nix/command.cc
@@ -106,8 +106,8 @@ void StorePathsCommand::run(ref<Store> store)
 
         if (recursive) {
             PathSet closure;
-            for (auto & storePath : storePaths)
-                store->computeFSClosure(storePath, closure, false, false);
+            store->computeFSClosure(PathSet(storePaths.begin(), storePaths.end()),
+                closure, false, false);
             storePaths = Paths(closure.begin(), closure.end());
         }
     }