From 8574b703424b73f6f75fc549b1738a6534d6a01e Mon Sep 17 00:00:00 2001 From: Guillaume Maudoux Date: Fri, 1 Mar 2019 01:15:10 +0100 Subject: [PATCH] fixup! Make roots a map of store paths to pinning links --- src/nix-store/nix-store.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/nix-store/nix-store.cc b/src/nix-store/nix-store.cc index b281ea2dd..89831eb3d 100644 --- a/src/nix-store/nix-store.cc +++ b/src/nix-store/nix-store.cc @@ -428,10 +428,10 @@ static void opQuery(Strings opFlags, Strings opArgs) referrers, true, settings.gcKeepOutputs, settings.gcKeepDerivations); } Roots roots = store->findRoots(); - for (auto & [path, roots] : roots) + for (auto & [path, links] : roots) if (referrers.find(path) != referrers.end()) - for (auto & root : roots) - cout << format("%1% -> %2%\n") % root % path; + for (auto & link : links) + cout << format("%1%\n") % link; break; }