diff --git a/src/test/fuzz/miniscript.cpp b/src/test/fuzz/miniscript.cpp index 1b791fc19c..73096cd5ca 100644 --- a/src/test/fuzz/miniscript.cpp +++ b/src/test/fuzz/miniscript.cpp @@ -253,7 +253,9 @@ using Type = miniscript::Type; using miniscript::operator"" _mst; //! Construct a miniscript node as a shared_ptr. -template NodeRef MakeNodeRef(Args&&... args) { return miniscript::MakeNodeRef(KEY_COMP, std::forward(args)...); } +template NodeRef MakeNodeRef(Args&&... args) { + return miniscript::MakeNodeRef(miniscript::internal::NoDupCheck{}, std::forward(args)...); +} /** Information about a yet to be constructed Miniscript node. */ struct NodeInfo { @@ -762,6 +764,7 @@ NodeRef GenNode(F ConsumeNode, Type root_type = ""_mst, bool strict_valid = fals } } assert(stack.size() == 1); + stack[0]->DuplicateKeyCheck(KEY_COMP); return std::move(stack[0]); }