Cleanups.

This commit is contained in:
JoelKatz
2012-11-05 19:09:23 -08:00
parent f111ca306c
commit ba09e48fc6
2 changed files with 4 additions and 2 deletions

View File

@@ -259,7 +259,7 @@ protected:
public:
SHAMapMissingNode(SHAMapType t, const SHAMapNode& nodeID, const uint256& nodeHash) :
std::runtime_error(nodeID.getString()), mType(t), mNodeID(nodeID), mNodeHash(nodeHash)
std::runtime_error("SHAMapMissingNode"), mType(t), mNodeID(nodeID), mNodeHash(nodeHash)
{ ; }
SHAMapMissingNode(SHAMapType t, const SHAMapNode& nodeID, const uint256& nodeHash, const uint256& targetIndex) :

View File

@@ -18,10 +18,12 @@
std::string SHAMapNode::getString() const
{
static boost::format NodeID("NodeID(%s,%s)");
if ((mDepth == 0) && (mNodeID.isZero()))
return "NodeID(root)";
return str(boost::format("NodeID(%s,%s)")
return str(NodeID
% boost::lexical_cast<std::string>(mDepth)
% mNodeID.GetHex());
}