about summary refs log tree commit diff
path: root/src/libexpr/primops.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/libexpr/primops.cc')
-rw-r--r--src/libexpr/primops.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/libexpr/primops.cc b/src/libexpr/primops.cc
index 9c217b373f..70560302ea 100644
--- a/src/libexpr/primops.cc
+++ b/src/libexpr/primops.cc
@@ -388,8 +388,10 @@ static void prim_derivationStrict(EvalState & state, Value * * args, Value & v)
         if (!useDrvAsSrc && isDerivation(path))
             if (explicitlyPassed)
                 drv.inputDrvs[path] = store -> queryDerivationOutputNames(path);
-            else
+            else if (drv.inputDrvs.find(path) == drv.inputDrvs.end())
                 drv.inputDrvs[path] = singleton<StringSet>(output);
+            else
+                drv.inputDrvs[path].insert(output);
         else
             drv.inputSrcs.insert(path);
     }