Skip to content

Commit 18ad54c

Browse files
committed
Bugfix: set x-only flag when inferring pk() inside tr()
1 parent 8fe6f5a commit 18ad54c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/script/descriptor.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1253,7 +1253,7 @@ std::unique_ptr<DescriptorImpl> InferScript(const CScript& script, ParseScriptCo
12531253
{
12541254
if (ctx == ParseScriptContext::P2TR && script.size() == 34 && script[0] == 32 && script[33] == OP_CHECKSIG) {
12551255
XOnlyPubKey key{Span{script}.subspan(1, 32)};
1256-
return std::make_unique<PKDescriptor>(InferXOnlyPubkey(key, ctx, provider));
1256+
return std::make_unique<PKDescriptor>(InferXOnlyPubkey(key, ctx, provider), true);
12571257
}
12581258

12591259
std::vector<std::vector<unsigned char>> data;

0 commit comments

Comments
 (0)