diff options
author | Antoine Poinsot <darosior@protonmail.com> | 2022-07-20 12:42:08 +0200 |
---|---|---|
committer | Antoine Poinsot <darosior@protonmail.com> | 2022-08-11 15:43:40 +0200 |
commit | b16f93caddcd3254eaf3dc43e09adf2142a9c40a (patch) | |
tree | 675b615337627dead3cde665e3bb3e951e54565f /src/wallet/scriptpubkeyman.cpp | |
parent | c232ef20c0fd2e3b55355e52684091cad3af5247 (diff) | |
download | bitcoin-b16f93caddcd3254eaf3dc43e09adf2142a9c40a.tar.xz |
script/sign: remove needless IsSolvable() utility
It was used back when we didn't have a concept of descriptor. Now we
can check for solvability using descriptors.
Diffstat (limited to 'src/wallet/scriptpubkeyman.cpp')
-rw-r--r-- | src/wallet/scriptpubkeyman.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wallet/scriptpubkeyman.cpp b/src/wallet/scriptpubkeyman.cpp index 1682ce2eef..b498ad5a17 100644 --- a/src/wallet/scriptpubkeyman.cpp +++ b/src/wallet/scriptpubkeyman.cpp @@ -1453,7 +1453,8 @@ void LegacyScriptPubKeyMan::LearnRelatedScripts(const CPubKey& key, OutputType t CTxDestination witdest = WitnessV0KeyHash(key.GetID()); CScript witprog = GetScriptForDestination(witdest); // Make sure the resulting program is solvable. - assert(IsSolvable(*this, witprog)); + const auto desc = InferDescriptor(witprog, *this); + assert(desc && desc->IsSolvable()); AddCScript(witprog); } } |