We have to track the high node ID of trusted validators as a tie-breaker.

1) Change return from getCurrentValidations
2) Log tiebreaker logic to aid debugging
3) Change checkLastClosedLedger to use the new tie-breaker logic
4) Log when we refuse to switch to our own previous ledger
5) Track node ID in the serialized validation object
6) Simplify getCurrentValidations ledger suppression logic
This commit is contained in:
JoelKatz
2012-10-05 03:46:24 -07:00
parent e17720717a
commit 0630a4b7f4
6 changed files with 72 additions and 42 deletions

View File

@@ -8,6 +8,7 @@ class SerializedValidation : public STObject
{
protected:
uint256 mPreviousHash;
uint160 mNodeID;
bool mTrusted;
void setNode();
@@ -26,6 +27,7 @@ public:
uint32 getSignTime() const;
uint32 getFlags() const;
NewcoinAddress getSignerPublic() const;
uint160 getNodeID() const { return mNodeID; }
bool isValid() const;
bool isFull() const;
bool isTrusted() const { return mTrusted; }