aboutsummaryrefslogtreecommitdiff
path: root/src/script/interpreter.cpp
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2014-11-20 15:23:05 +0100
committerPieter Wuille <pieter.wuille@gmail.com>2014-11-20 15:27:39 +0100
commit3ba5ebc065ce9fceba8f9de7579debc5b49c3ba8 (patch)
tree0e5d1d4782c4405ff5d7a9cb806853e5428a1f1b /src/script/interpreter.cpp
parentcf9c4887f176634c9f39305ad70657d9fff3962d (diff)
parent03914234b3c9c35d66b51d580fe727a0707394ca (diff)
downloadbitcoin-3ba5ebc065ce9fceba8f9de7579debc5b49c3ba8.tar.xz
Merge pull request #5000
0391423 Discourage NOPs reserved for soft-fork upgrades (Peter Todd)
Diffstat (limited to 'src/script/interpreter.cpp')
-rw-r--r--src/script/interpreter.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/script/interpreter.cpp b/src/script/interpreter.cpp
index cf81fe30a2..760086eaba 100644
--- a/src/script/interpreter.cpp
+++ b/src/script/interpreter.cpp
@@ -329,8 +329,14 @@ bool EvalScript(vector<vector<unsigned char> >& stack, const CScript& script, un
// Control
//
case OP_NOP:
+ break;
+
case OP_NOP1: case OP_NOP2: case OP_NOP3: case OP_NOP4: case OP_NOP5:
case OP_NOP6: case OP_NOP7: case OP_NOP8: case OP_NOP9: case OP_NOP10:
+ {
+ if (flags & SCRIPT_VERIFY_DISCOURAGE_UPGRADABLE_NOPS)
+ return set_error(serror, SCRIPT_ERR_DISCOURAGE_UPGRADABLE_NOPS);
+ }
break;
case OP_IF: