Skip to content

Commit

Permalink
Rename flags in code example to match implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
btcdrak committed Nov 23, 2015
1 parent 83fc19d commit 8ad8cad
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions bip-0068.mediawiki
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,12 @@ This is proposed to be accomplished by replacing IsFinalTx() and CheckFinalTx(),
/* If this flag set, CTxIn::nSequence is NOT interpreted as a
* relative lock-time. Setting the most significant bit of a
* sequence number disabled relative lock-time. */
static const uint32_t SEQUENCE_LOCKTIME_DISABLED_FLAG = (1 << 31);
static const uint32_t SEQUENCE_LOCKTIME_DISABLE_FLAG = (1 << 31);
/* If CTxIn::nSequence encodes a relative lock-time and this flag
* is set, the relative lock-time has units of 512 seconds,
* otherwise it specifies blocks with a granularity of 1. */
static const uint32_t SEQUENCE_LOCKTIME_SECONDS_FLAG = (1 << 22);
static const uint32_t SEQUENCE_LOCKTIME_TYPE_FLAG = (1 << 22);
/* If CTxIn::nSequence encodes a relative lock-time, this mask is
* applied to extract that lock-time from the sequence field. */
Expand Down Expand Up @@ -117,15 +117,15 @@ This is proposed to be accomplished by replacing IsFinalTx() and CheckFinalTx(),
// Sequence numbers with the most significant bit set are not
// treated as relative lock-times, nor are they given any
// consensus-enforced meaning at this point.
if (txin.nSequence & CTxIn::SEQUENCE_LOCKTIME_DISABLED_FLAG)
if (txin.nSequence & CTxIn::SEQUENCE_LOCKTIME_DISABLE_FLAG)
continue;
if (prevHeights == NULL)
continue;
int nCoinHeight = (*prevHeights)[txinIndex];
if (txin.nSequence & CTxIn::SEQUENCE_LOCKTIME_SECONDS_FLAG) {
if (txin.nSequence & CTxIn::SEQUENCE_LOCKTIME_TYPE_FLAG) {
int64_t nCoinTime = block.GetAncestor(std::max(nCoinHeight-1, 0))->GetMedianTimePast();
Expand Down

0 comments on commit 8ad8cad

Please sign in to comment.