| 15 | #include <utilmoneystr.h> |
| 16 | |
| 17 | bool IsFinalTx(const CTransaction &tx, int nBlockHeight, int64_t nBlockTime) |
| 18 | { |
| 19 | if (tx.nLockTime == 0) |
| 20 | return true; |
| 21 | if ((int64_t)tx.nLockTime < ((int64_t)tx.nLockTime < LOCKTIME_THRESHOLD ? (int64_t)nBlockHeight : nBlockTime)) |
| 22 | return true; |
| 23 | for (const auto& txin : tx.vin) { |
| 24 | if (!(txin.nSequence == CTxIn::SEQUENCE_FINAL)) |
| 25 | return false; |
| 26 | } |
| 27 | return true; |
| 28 | } |
| 29 | |
| 30 | std::pair<int, int64_t> CalculateSequenceLocks(const CTransaction &tx, int flags, std::vector<int>* prevHeights, const CBlockIndex& block) |
| 31 | { |
no outgoing calls