diff options
author | Pieter Wuille <pieter.wuille@gmail.com> | 2019-04-04 12:45:32 -0700 |
---|---|---|
committer | Pieter Wuille <pieter.wuille@gmail.com> | 2019-04-04 12:45:32 -0700 |
commit | 9a93c91c882265c908ea18496cd1bc271be914d4 (patch) | |
tree | 951170f401410645ef47f18a58d6e2a68b766935 /src/script/sign.cpp | |
parent | daef20fb50c00240ea4a5d653f3a47ee604d25c1 (diff) |
Keep full pubkeys in FlatSigningProvider::origins
Diffstat (limited to 'src/script/sign.cpp')
-rw-r--r-- | src/script/sign.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/script/sign.cpp b/src/script/sign.cpp index 320956d0c4..36dd68a3d8 100644 --- a/src/script/sign.cpp +++ b/src/script/sign.cpp @@ -483,7 +483,13 @@ bool HidingSigningProvider::GetKeyOrigin(const CKeyID& keyid, KeyOriginInfo& inf bool FlatSigningProvider::GetCScript(const CScriptID& scriptid, CScript& script) const { return LookupHelper(scripts, scriptid, script); } bool FlatSigningProvider::GetPubKey(const CKeyID& keyid, CPubKey& pubkey) const { return LookupHelper(pubkeys, keyid, pubkey); } -bool FlatSigningProvider::GetKeyOrigin(const CKeyID& keyid, KeyOriginInfo& info) const { return LookupHelper(origins, keyid, info); } +bool FlatSigningProvider::GetKeyOrigin(const CKeyID& keyid, KeyOriginInfo& info) const +{ + std::pair<CPubKey, KeyOriginInfo> out; + bool ret = LookupHelper(origins, keyid, out); + if (ret) info = std::move(out.second); + return ret; +} bool FlatSigningProvider::GetKey(const CKeyID& keyid, CKey& key) const { return LookupHelper(keys, keyid, key); } FlatSigningProvider Merge(const FlatSigningProvider& a, const FlatSigningProvider& b) |