aboutsummaryrefslogtreecommitdiff
path: root/src/script/ismine.cpp
diff options
context:
space:
mode:
authorWladimir J. van der Laan <[email protected]>2018-04-12 22:30:41 +0200
committerWladimir J. van der Laan <[email protected]>2018-04-12 22:55:56 +0200
commit8480d41e0f9d466447f49bf5dd7c17c5337af77a (patch)
treef3f74917b997046c908f2b3a19770818fc3e0b08 /src/script/ismine.cpp
parentMerge #12888: debug log number of unknown wallet records on load (diff)
parentMake DummySignatureCreator a singleton (diff)
downloaddiscoin-8480d41e0f9d466447f49bf5dd7c17c5337af77a.tar.xz
discoin-8480d41e0f9d466447f49bf5dd7c17c5337af77a.zip
Merge #12803: Make BaseSignatureCreator a pure interface
be67831 Make DummySignatureCreator a singleton (Pieter Wuille) 190b8d2 Make BaseSignatureCreator a pure interface (Pieter Wuille) Pull request description: * Removes the `m_provider` field from `BaseSignatureCreator`. Instead both a `SigningProvider` (which provides keys and scripts) and a `BaseSignatureCreator` (which implements the transaction-specific (or other) signing logic) are passed into and down in `ProduceSignature`, making the two concepts orthogonal. * Makes `BaseSignatureCreator` a pure interface without constructor, making it easier to implement new derivations of it (for example for message signing). * As `DummySignatureCreator` now becomes a stateless object, turn it into a singleton `DUMMY_SIGNATURE_CREATOR`. Tree-SHA512: 5f1f4512e4ea7d02a31df7b9ede55008efa716c5b74a2630ca1c2fc6599584d8bf5f5641487266127f4b3788033803539fbd22b03ef1219c83c10da2d3da3dcd
Diffstat (limited to 'src/script/ismine.cpp')
-rw-r--r--src/script/ismine.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/ismine.cpp b/src/script/ismine.cpp
index 05bc5e9bd..b826bcfe2 100644
--- a/src/script/ismine.cpp
+++ b/src/script/ismine.cpp
@@ -146,7 +146,7 @@ isminetype IsMine(const CKeyStore &keystore, const CScript& scriptPubKey, bool&
if (keystore.HaveWatchOnly(scriptPubKey)) {
// TODO: This could be optimized some by doing some work after the above solver
SignatureData sigs;
- return ProduceSignature(DummySignatureCreator(&keystore), scriptPubKey, sigs) ? ISMINE_WATCH_SOLVABLE : ISMINE_WATCH_UNSOLVABLE;
+ return ProduceSignature(keystore, DUMMY_SIGNATURE_CREATOR, scriptPubKey, sigs) ? ISMINE_WATCH_SOLVABLE : ISMINE_WATCH_UNSOLVABLE;
}
return ISMINE_NO;
}