Skip to content

Commit 7e2fa5c

Browse files
committed
[WIP] Fix builds
1 parent 8ad2cb3 commit 7e2fa5c

File tree

3 files changed

+11
-1
lines changed

3 files changed

+11
-1
lines changed

src/xrpld/app/consensus/RCLValidations.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ handleNewValidation(
190190

191191
// masterKey is seated only if validator is trusted or listed
192192
auto const nodeKey = masterKey.value_or(signingKey);
193-
assert(nodeKey != app.getValidationPublicKey());
193+
// assert(nodeKey != app.getValidationPublicKey());
194194
auto const outcome = validations.add(calcNodeID(nodeKey), val);
195195

196196
if (outcome == ValStatus::current)

src/xrpld/app/misc/NetworkOPs.cpp

+9
Original file line numberDiff line numberDiff line change
@@ -1887,6 +1887,15 @@ NetworkOPsImp::beginConsensus(uint256 const& networkClosed)
18871887
bool
18881888
NetworkOPsImp::processTrustedProposal(RCLCxPeerPos peerPos)
18891889
{
1890+
if (auto const localPk = app_.getValidationPublicKey())
1891+
{
1892+
auto const localID = calcNodeID(*localPk);
1893+
auto const& peerID = peerPos.proposal().nodeID();
1894+
assert(localID != peerID);
1895+
if (localID == peerID)
1896+
return false;
1897+
}
1898+
18901899
return mConsensus.peerProposal(app_.timeKeeper().closeTime(), peerPos);
18911900
}
18921901

src/xrpld/consensus/ConsensusParms.h

+1
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
#include <cstddef>
2626
#include <functional>
2727
#include <map>
28+
#include <optional>
2829

2930
namespace ripple {
3031

0 commit comments

Comments
 (0)