File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -662,6 +662,14 @@ void CTxMemPool::check(const CCoinsViewCache* pcoins) const
662662 }
663663 i++;
664664 }
665+ // sapling txes
666+ if (tx.IsShieldedTx ()) {
667+ for (const SpendDescription& sd : tx.sapData ->vShieldedSpend ) {
668+ SaplingMerkleTree tree;
669+ assert (pcoins->GetSaplingAnchorAt (sd.anchor , tree));
670+ assert (!pcoins->GetNullifier (sd.nullifier ));
671+ }
672+ }
665673 assert (setParentCheck == GetMemPoolParents (it));
666674 // Check children against mapNextTx
667675 if (!fHasZerocoinSpends ) {
@@ -718,7 +726,7 @@ void CTxMemPool::check(const CCoinsViewCache* pcoins) const
718726 }
719727 }
720728 for (std::map<COutPoint, CInPoint>::const_iterator it = mapNextTx.begin (); it != mapNextTx.end (); it++) {
721- uint256 hash = it->second .ptx ->GetHash ();
729+ const uint256& hash = it->second .ptx ->GetHash ();
722730 indexed_transaction_set::const_iterator it2 = mapTx.find (hash);
723731 const CTransaction& tx = it2->GetTx ();
724732 assert (it2 != mapTx.end ());
You can’t perform that action at this time.
0 commit comments