diff options
Diffstat (limited to 'src/script/descriptor.cpp')
-rw-r--r-- | src/script/descriptor.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/script/descriptor.cpp b/src/script/descriptor.cpp index 8ace9c3136..434e106dad 100644 --- a/src/script/descriptor.cpp +++ b/src/script/descriptor.cpp @@ -1472,6 +1472,10 @@ std::unique_ptr<DescriptorImpl> ParseScript(uint32_t& key_exp_index, Span<const } if (ctx == ParseScriptContext::TOP && Func("rawtr", expr)) { auto arg = Expr(expr); + if (expr.size()) { + error = strprintf("rawtr(): only one key expected."); + return nullptr; + } auto output_key = ParsePubkey(key_exp_index, arg, ParseScriptContext::P2TR, out, error); if (!output_key) return nullptr; ++key_exp_index; |