policy: Remove unused locktime flags
Summary:
The locktime flags have many issues: They are passed in by a default argument, which is fragile. It has already lead to bugs like the one fixed in commit e30b6ea. They are negative (signed), which doesn't make sense for flags (unsigned in general). According to the review comments when the code was added: "The max on the flags is a fairly weird operation." ( BIP-113: Mempool-only median time-past as endpoint for lock-time calculationsĀ #6566 (comment)) No call site relies on the default argument and they all pass in a single compile-time constant, rendering most of the code dead and untested. The dead code calls GetAdjustedTime (network adjusted time), which has its own issues. See AddTimeData will never update nTimeOffset past 199 samplesĀ #4521 Fix all issues by removing them
Backport of core#24080.
Test Plan:
ninja all check-all
Reviewers: #bitcoin_abc, sdulfari
Reviewed By: #bitcoin_abc, sdulfari
Subscribers: sdulfari
Differential Revision: https://reviews.bitcoinabc.org/D12951