| 978 | } |
| 979 | |
| 980 | bool TestLockPointValidity(const LockPoints* lp) |
| 981 | { |
| 982 | AssertLockHeld(cs_main); |
| 983 | assert(lp); |
| 984 | // If there are relative lock times then the maxInputBlock will be set |
| 985 | // If there are no relative lock times, the LockPoints don't depend on the chain |
| 986 | if (lp->maxInputBlock) { |
| 987 | // Check whether chainActive is an extension of the block at which the LockPoints |
| 988 | // calculation was valid. If not LockPoints are no longer valid |
| 989 | if (!chainActive.Contains(lp->maxInputBlock)) { |
| 990 | return false; |
| 991 | } |
| 992 | } |
| 993 | |
| 994 | // LockPoints still valid |
| 995 | return true; |
| 996 | } |
| 997 | |
| 998 | bool CheckSequenceLocks(const CTransaction &tx, int flags, LockPoints* lp, bool useExistingLockPoints) |
| 999 | { |
no test coverage detected