1
0
Fork 0
mirror of https://github.com/bitcoin/bips.git synced 2025-03-13 19:16:49 +01:00

BIP 8: Remove impossible direct path from DEFINED to FAILING

This commit is contained in:
Luke Dashjr 2020-06-26 15:12:06 +00:00
parent a59aaceffc
commit 8e906f14af
3 changed files with 2 additions and 7 deletions

View file

@ -110,12 +110,9 @@ Otherwise, the next state depends on the previous state:
switch (GetStateForBlock(GetAncestorAtHeight(block, block.height - 2016))) { switch (GetStateForBlock(GetAncestorAtHeight(block, block.height - 2016))) {
We remain in the initial state until either we pass the start block height or the timeout height. We remain in the initial state until we reach the start block height.
case DEFINED: case DEFINED:
if (block.height >= timeoutheight) {
return (lockinontimeout == true) ? LOCKED_IN : FAILING;
}
if (block.height >= startheight) { if (block.height >= startheight) {
return STARTED; return STARTED;
} }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 25 KiB

View file

@ -25,7 +25,7 @@
<text x="176" y="72" font-size="20" text-anchor="middle">DEFINED</text> <text x="176" y="72" font-size="20" text-anchor="middle">DEFINED</text>
<path d="M 128 80 a 24 32 0 1 1 0 -32"/><!-- loop --> <path d="M 128 80 a 24 32 0 1 1 0 -32"/><!-- loop -->
<path d="M 176 80 l 0 96"/> <path d="M 176 80 l 0 96"/>
<text x="182" y="128" font-size="12" text-anchor="start">startheight &lt;= height &lt; timeoutheight</text> <text x="182" y="128" font-size="12" text-anchor="start">startheight &lt;= height</text>
<rect x="112" y="176" width="128" height="32"/> <rect x="112" y="176" width="128" height="32"/>
<text x="176" y="200" font-size="20" text-anchor="middle">STARTED</text> <text x="176" y="200" font-size="20" text-anchor="middle">STARTED</text>
<path d="M 128 208 a 24 32 0 1 1 0 -32"/><!-- loop --> <path d="M 128 208 a 24 32 0 1 1 0 -32"/><!-- loop -->
@ -43,8 +43,6 @@
<rect x="640" y="176" width="128" height="32"/> <rect x="640" y="176" width="128" height="32"/>
<text x="704" y="200" font-size="20" text-anchor="middle">FAILING</text> <text x="704" y="200" font-size="20" text-anchor="middle">FAILING</text>
<path d="M 240 64 l 400 112"/>
<text x="440" y="108" font-size="12" text-anchor="start">timeoutheight &lt;= height</text>
<path d="M 240 192 l 400 0"/> <path d="M 240 192 l 400 0"/>
<text x="408" y="184" font-size="12" text-anchor="middle">(lockinontimeout == false) AND (timeoutheight &lt;= height)</text> <text x="408" y="184" font-size="12" text-anchor="middle">(lockinontimeout == false) AND (timeoutheight &lt;= height)</text>
<path d="M 704 208 l 0 176"/> <path d="M 704 208 l 0 176"/>

Before

Width:  |  Height:  |  Size: 2.6 KiB

After

Width:  |  Height:  |  Size: 2.5 KiB