nixos/utils: fix stack overflow in genJqReplacementSnippet (#284027)

When the input contains derivations, don't attempt to recurse into them
This commit is contained in:
Yureka 2024-01-30 11:00:08 +01:00 committed by GitHub
parent fd400a9585
commit c94d63a527
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -109,6 +109,7 @@ rec {
recurse = prefix: item: recurse = prefix: item:
if item ? ${attr} then if item ? ${attr} then
nameValuePair prefix item.${attr} nameValuePair prefix item.${attr}
else if isDerivation item then []
else if isAttrs item then else if isAttrs item then
map (name: map (name:
let let