From 59b49cd07482494d9a99068af502be9ceda41ed2 Mon Sep 17 00:00:00 2001 From: Suhas Daftuar Date: Sat, 11 Jul 2015 06:52:35 -0400 Subject: [PATCH] Eliminate signed/unsigned comparison warning --- src/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.cpp b/src/main.cpp index 87750f9ea..875b7b706 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -2849,7 +2849,7 @@ bool AcceptBlock(CBlock& block, CValidationState& state, CBlockIndex** ppindex, // blocks which are too close in height to the tip. Apply this test // regardless of whether pruning is enabled; it should generally be safe to // not process unrequested blocks. - bool fTooFarAhead = (pindex->nHeight - chainActive.Height()) > MIN_BLOCKS_TO_KEEP; + bool fTooFarAhead = (pindex->nHeight > int(chainActive.Height() + MIN_BLOCKS_TO_KEEP)); // TODO: deal better with return value and error conditions for duplicate // and unrequested blocks.