Refactor script validation to observe amounts

This commit is contained in:
Pieter Wuille
2016-03-31 14:51:29 +02:00
committed by lateminer
parent c6238629b3
commit 81e04cabfe
13 changed files with 48 additions and 36 deletions

View File

@@ -1899,7 +1899,7 @@ void UpdateCoins(const CTransaction& tx, CValidationState &state, CCoinsViewCach
bool CScriptCheck::operator()() {
const CScript &scriptSig = ptxTo->vin[nIn].scriptSig;
if (!VerifyScript(scriptSig, scriptPubKey, nFlags, CachingTransactionSignatureChecker(ptxTo, nIn, cacheStore), &error)) {
if (!VerifyScript(scriptSig, scriptPubKey, nFlags, CachingTransactionSignatureChecker(ptxTo, nIn, amount, cacheStore), &error)) {
return false;
}
return true;