about summary refs log tree commit diff
path: root/src/nix.cc
diff options
context:
space:
mode:
authorEelco Dolstra <e.dolstra@tudelft.nl>2003-10-16T08·06+0000
committerEelco Dolstra <e.dolstra@tudelft.nl>2003-10-16T08·06+0000
commit181aa3dc4198d2e2cfa89d3ebb53a96fa567e12f (patch)
treec79b461ddef5dd399476a6ea95ec5068b591808e /src/nix.cc
parentebff82222c7b946e70e539389c0027529b6c7ad0 (diff)
* Don't sort the result of `--query --list'.
Diffstat (limited to 'src/nix.cc')
-rw-r--r--src/nix.cc10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/nix.cc b/src/nix.cc
index a4d2898f1585..1875689990a4 100644
--- a/src/nix.cc
+++ b/src/nix.cc
@@ -93,17 +93,15 @@ static void opQuery(Strings opFlags, Strings opArgs)
     switch (query) {
         
         case qList: {
-            PathSet paths;
             for (Strings::iterator i = opArgs.begin();
                  i != opArgs.end(); i++)
             {
-                StringSet paths2 = nixExprRoots(
+                StringSet paths = nixExprRoots(
                     maybeNormalise(checkPath(*i), normalise));
-                paths.insert(paths2.begin(), paths2.end());
+                for (StringSet::iterator j = paths.begin(); 
+                     j != paths.end(); j++)
+                    cout << format("%s\n") % *j;
             }
-            for (StringSet::iterator i = paths.begin(); 
-                 i != paths.end(); i++)
-                cout << format("%s\n") % *i;
             break;
         }