Merge #10792: Replace MAX_OPCODE for OP_NOP10.
c8e29d7
Replace MAX_OPCODE for OP_NOP10. (Mark Friedenbach)
Tree-SHA512: f6a4129db24fe3feb044acaec3b94194cc4fa909de3d0a45a664b32f886a7d8ab997c9cb6ff0870c4aee66d8e038cf0453dbbb518316829d15e84da9882f3e69
This commit is contained in:
commit
badd81bd31
2 changed files with 4 additions and 4 deletions
|
@ -27,7 +27,7 @@ CScript ParseScript(const std::string& s)
|
||||||
|
|
||||||
if (mapOpNames.empty())
|
if (mapOpNames.empty())
|
||||||
{
|
{
|
||||||
for (int op = 0; op <= OP_NOP10; op++)
|
for (int op = 0; op <= MAX_OPCODE; op++)
|
||||||
{
|
{
|
||||||
// Allow OP_RESERVED to get into mapOpNames
|
// Allow OP_RESERVED to get into mapOpNames
|
||||||
if (op < OP_NOP && op != OP_RESERVED)
|
if (op < OP_NOP && op != OP_RESERVED)
|
||||||
|
|
|
@ -240,7 +240,7 @@
|
||||||
["0", "IF NOP10 ENDIF 1", "P2SH,STRICTENC,DISCOURAGE_UPGRADABLE_NOPS", "OK",
|
["0", "IF NOP10 ENDIF 1", "P2SH,STRICTENC,DISCOURAGE_UPGRADABLE_NOPS", "OK",
|
||||||
"Discouraged NOPs are allowed if not executed"],
|
"Discouraged NOPs are allowed if not executed"],
|
||||||
|
|
||||||
["0", "IF 0xba ELSE 1 ENDIF", "P2SH,STRICTENC", "OK", "opcodes above NOP10 invalid if executed"],
|
["0", "IF 0xba ELSE 1 ENDIF", "P2SH,STRICTENC", "OK", "opcodes above MAX_OPCODE invalid if executed"],
|
||||||
["0", "IF 0xbb ELSE 1 ENDIF", "P2SH,STRICTENC", "OK"],
|
["0", "IF 0xbb ELSE 1 ENDIF", "P2SH,STRICTENC", "OK"],
|
||||||
["0", "IF 0xbc ELSE 1 ENDIF", "P2SH,STRICTENC", "OK"],
|
["0", "IF 0xbc ELSE 1 ENDIF", "P2SH,STRICTENC", "OK"],
|
||||||
["0", "IF 0xbd ELSE 1 ENDIF", "P2SH,STRICTENC", "OK"],
|
["0", "IF 0xbd ELSE 1 ENDIF", "P2SH,STRICTENC", "OK"],
|
||||||
|
@ -878,7 +878,7 @@
|
||||||
"P2SH,DISCOURAGE_UPGRADABLE_NOPS", "DISCOURAGE_UPGRADABLE_NOPS", "Discouraged NOP10 in redeemScript"],
|
"P2SH,DISCOURAGE_UPGRADABLE_NOPS", "DISCOURAGE_UPGRADABLE_NOPS", "Discouraged NOP10 in redeemScript"],
|
||||||
|
|
||||||
["0x50","1", "P2SH,STRICTENC", "BAD_OPCODE", "opcode 0x50 is reserved"],
|
["0x50","1", "P2SH,STRICTENC", "BAD_OPCODE", "opcode 0x50 is reserved"],
|
||||||
["1", "IF 0xba ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE", "opcodes above NOP10 invalid if executed"],
|
["1", "IF 0xba ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE", "opcodes above MAX_OPCODE invalid if executed"],
|
||||||
["1", "IF 0xbb ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE"],
|
["1", "IF 0xbb ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE"],
|
||||||
["1", "IF 0xbc ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE"],
|
["1", "IF 0xbc ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE"],
|
||||||
["1", "IF 0xbd ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE"],
|
["1", "IF 0xbd ELSE 1 ENDIF", "P2SH,STRICTENC", "BAD_OPCODE"],
|
||||||
|
@ -1001,7 +1001,7 @@
|
||||||
["1","RESERVED", "P2SH,STRICTENC", "BAD_OPCODE", "OP_RESERVED is reserved"],
|
["1","RESERVED", "P2SH,STRICTENC", "BAD_OPCODE", "OP_RESERVED is reserved"],
|
||||||
["1","RESERVED1", "P2SH,STRICTENC", "BAD_OPCODE", "OP_RESERVED1 is reserved"],
|
["1","RESERVED1", "P2SH,STRICTENC", "BAD_OPCODE", "OP_RESERVED1 is reserved"],
|
||||||
["1","RESERVED2", "P2SH,STRICTENC", "BAD_OPCODE", "OP_RESERVED2 is reserved"],
|
["1","RESERVED2", "P2SH,STRICTENC", "BAD_OPCODE", "OP_RESERVED2 is reserved"],
|
||||||
["1","0xba", "P2SH,STRICTENC", "BAD_OPCODE", "0xba == OP_NOP10 + 1"],
|
["1","0xba", "P2SH,STRICTENC", "BAD_OPCODE", "0xba == MAX_OPCODE + 1"],
|
||||||
|
|
||||||
["2147483648", "1ADD 1", "P2SH,STRICTENC", "UNKNOWN_ERROR", "We cannot do math on 5-byte integers"],
|
["2147483648", "1ADD 1", "P2SH,STRICTENC", "UNKNOWN_ERROR", "We cannot do math on 5-byte integers"],
|
||||||
["2147483648", "NEGATE 1", "P2SH,STRICTENC", "UNKNOWN_ERROR", "We cannot do math on 5-byte integers"],
|
["2147483648", "NEGATE 1", "P2SH,STRICTENC", "UNKNOWN_ERROR", "We cannot do math on 5-byte integers"],
|
||||||
|
|
Loading…
Reference in a new issue