Merge pull request #3860 from petertodd/test-checkmulti-n-m-zero

Test CHECKMULTISIG with m == 0 and/or n == 0
This commit is contained in:
Gavin Andresen
2014-05-09 10:00:16 -04:00
3 changed files with 107 additions and 1 deletions

View File

@@ -67,7 +67,11 @@ ParseScript(string s)
BOOST_FOREACH(string w, words)
{
if (all(w, is_digit()) ||
if (w.size() == 0)
{
// Empty string, ignore. (boost::split given '' will return one word)
}
else if (all(w, is_digit()) ||
(starts_with(w, "-") && all(string(w.begin()+1, w.end()), is_digit())))
{
// Number