Changeset View
Changeset View
Standalone View
Standalone View
src/test/sigcache_tests.cpp
Show All 26 Lines | |||||
/** | /** | ||||
* Sigcache is only accessible via CachingTransactionSignatureChecker | * Sigcache is only accessible via CachingTransactionSignatureChecker | ||||
* as friend. | * as friend. | ||||
*/ | */ | ||||
class TestCachingTransactionSignatureChecker { | class TestCachingTransactionSignatureChecker { | ||||
CachingTransactionSignatureChecker *pchecker; | CachingTransactionSignatureChecker *pchecker; | ||||
public: | public: | ||||
TestCachingTransactionSignatureChecker( | explicit TestCachingTransactionSignatureChecker( | ||||
CachingTransactionSignatureChecker &checkerarg) { | CachingTransactionSignatureChecker &checkerarg) { | ||||
pchecker = &checkerarg; | pchecker = &checkerarg; | ||||
} | } | ||||
inline bool VerifyAndStore(const std::vector<uint8_t> &vchSig, | inline bool VerifyAndStore(const std::vector<uint8_t> &vchSig, | ||||
const CPubKey &pubkey, const uint256 &sighash) { | const CPubKey &pubkey, const uint256 &sighash) { | ||||
return pchecker->VerifySignature(vchSig, pubkey, sighash); | return pchecker->VerifySignature(vchSig, pubkey, sighash); | ||||
} | } | ||||
▲ Show 20 Lines • Show All 75 Lines • Show Last 20 Lines |