diff --git a/src/rpcblockchain.cpp b/src/rpcblockchain.cpp index 8493b42a4ae6..b21a99499ea4 100644 --- a/src/rpcblockchain.cpp +++ b/src/rpcblockchain.cpp @@ -38,12 +38,12 @@ double GetDifficulty(const CBlockIndex* blockindex) double dDiff = (double)0x0000ffff / (double)(blockindex->nBits & 0x00ffffff); - while (nShift < 29) + while (nShift < 30) { dDiff *= 256.0; nShift++; } - while (nShift > 29) + while (nShift > 30) { dDiff /= 256.0; nShift--;