diff options
author | Gavin Andresen <gavinandresen@gmail.com> | 2010-10-19 14:17:18 -0400 |
---|---|---|
committer | Gavin Andresen <gavinandresen@gmail.com> | 2010-10-19 14:17:18 -0400 |
commit | d1e4a866adc92fd456c0a3139dcaefeb47b8c025 (patch) | |
tree | 0ec5e0817784154794dd9b43695cf0b72291406c /script.cpp | |
parent | 2bda554be4a7fc38075f93d301d971df31b2a27d (diff) | |
parent | 5cbf75324d1509a1262b65c5073314a4da3f6d77 (diff) |
Merge remote branch 'refs/remotes/svn/trunk' into svn
Diffstat (limited to 'script.cpp')
-rw-r--r-- | script.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/script.cpp b/script.cpp index 730c4986d2..a09031bad5 100644 --- a/script.cpp +++ b/script.cpp @@ -776,16 +776,11 @@ bool EvalScript(vector<vector<unsigned char> >& stack, const CScript& script, co return false; int nKeysCount = CastToBigNum(stacktop(-i)).getint(); - if (nKeysCount < 0) + if (nKeysCount < 0 || nKeysCount > 20) + return false; + nOpCount += nKeysCount; + if (nOpCount > 201) return false; - if (nBestHeight > 84000) - { - if (nKeysCount > 20) - return false; - nOpCount += nKeysCount; - if (nOpCount > 201) - return false; - } int ikey = ++i; i += nKeysCount; if (stack.size() < i) |