Merge pull request #6061

eb83719 Consensus: Refactor: Separate Consensus::CheckTxInputs and GetSpendHeight in CheckInputs (Jorge Timón)
This commit is contained in:
Wladimir J. van der Laan
2015-06-10 18:04:08 +02:00
2 changed files with 28 additions and 9 deletions

View File

@@ -487,4 +487,11 @@ extern CCoinsViewCache *pcoinsTip;
/** Global variable that points to the active block tree (protected by cs_main) */
extern CBlockTreeDB *pblocktree;
/**
* Return the spend height, which is one more than the inputs.GetBestBlock().
* While checking, GetBestBlock() refers to the parent block. (protected by cs_main)
* This is also true for mempool checks.
*/
int GetSpendHeight(const CCoinsViewCache& inputs);
#endif // BITCOIN_MAIN_H