A zere-length inner node is legal if the tree is empty.

This commit is contained in:
JoelKatz
2012-05-31 20:51:37 -07:00
parent 63b806b597
commit 11a85647ac

View File

@@ -195,7 +195,7 @@ SHAMapTreeNode::SHAMapTreeNode(const SHAMapNode& id, const std::vector<unsigned
int type = s.removeLastByte();
int len = s.getLength();
if ((type < 0) || (type > 3) || (len < 32)) throw SHAMapException(InvalidNode);
if ((type < 0) || (type > 3)) throw SHAMapException(InvalidNode);
if (type == 0)
{ // transaction