Bugfixes.

This commit is contained in:
JoelKatz
2012-05-31 20:55:30 -07:00
parent a4abe5a9dc
commit 2ec46c0dbf
3 changed files with 21 additions and 12 deletions

View File

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