Remove values coming from the original sources because this may cause the evaluation of unsafe code.

Instead add the computed value under tryEval to catch bad evaluations.

svn path=/nixpkgs/trunk/; revision=17453
This commit is contained in:
Nicolas Pierron 2009-09-26 23:01:35 +00:00
parent b642db4d0e
commit 13f467fc84

View File

@ -211,14 +211,15 @@ rec {
declarations =
map (m: {
source = m.key;
value = m.options;
}) (declarationsOf name);
definitions =
map (m: {
source = m.key;
value = m.config;
}) (definitionsOf name);
config = builtins.tryEval
(lib.getAttr name result.config);
}
else if all isAttrs values then
(recurseInto name modules).options