about summary refs log tree commit diff
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2014-03-11T16·31+0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2014-03-11T16·34+0100
commit25386e5edc2d65c84ce824d2c964a5c029f4c30d (patch)
tree50c48aaee4af709d451262da759723754bdd7169
parent92a848f674f371d675f461d2a7a6810d492dd4ea (diff)
Fix passing meta attribute to buildenv.nix
Since the meta attributes were not sorted, attribute lookup could
fail, leading to package priorities and active flags not working
correctly.

Broken since 0f24400d90daf65cf20142a662f8245008437e2c.
-rw-r--r--src/nix-env/user-env.cc1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/nix-env/user-env.cc b/src/nix-env/user-env.cc
index 75f5b54abf0a..a95c4cba937f 100644
--- a/src/nix-env/user-env.cc
+++ b/src/nix-env/user-env.cc
@@ -91,6 +91,7 @@ bool createUserEnv(EvalState & state, DrvInfos & elems,
             if (!v) continue;
             vMeta.attrs->push_back(Attr(state.symbols.create(*j), v));
         }
+        vMeta.attrs->sort();
         v.attrs->sort();
 
         if (drvPath != "") references.insert(drvPath);