AcceptToMemoryPool: Re-add missing code comment

The comment on `view.SetBackend(dummy)` was removed when we backported
upstream locking PRs in zcash/zcash#5017. The upstream commit in
question removed a locking scope but did not remove the reference to
that scope in the comment. Our backport removed the outdated comment,
but should have modified it instead, because otherwise the existence of
`view.SetBackend(dummy)` is very confusing (as it disconnects the cache
from `pcoinsTip`, on the assumption that everything we need from it has
been cached via calls to `CCoinsViewCache::HaveCoins` and
`CCoinsViewCache::HaveShieldedRequirements`).
This commit is contained in:
Jack Grigg 2022-04-01 20:09:56 +00:00
parent c99e7752e4
commit bb072f06c9
1 changed files with 1 additions and 0 deletions

View File

@ -1892,6 +1892,7 @@ bool AcceptToMemoryPool(
nValueIn = view.GetValueIn(tx);
// we have all inputs cached now, so switch back to dummy
view.SetBackend(dummy);
// Check for non-standard pay-to-script-hash in inputs