Skip to content

Commit

Permalink
AbstractBlockChain: Print error msg before throwing BlockVersionOutOf…
Browse files Browse the repository at this point in the history
…Date exception
  • Loading branch information
oscarguindzberg committed Dec 20, 2018
1 parent fd3a526 commit fc7c587
Showing 1 changed file with 1 addition and 0 deletions.
Expand Up @@ -552,6 +552,7 @@ private void connectBlock(final Block block, StoredBlock storedPrev, boolean exp
final Integer count = versionTally.getCountAtOrAbove(block.getVersion() + 1);
if (count != null
&& count >= params.getMajorityRejectBlockOutdated()) {
log.error("Block with hash {} has outdated version: version # = {}" , block.getHashAsString(), block.getVersion());
throw new VerificationException.BlockVersionOutOfDate(block.getVersion());
}
}
Expand Down

0 comments on commit fc7c587

Please sign in to comment.