aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGavin Andresen <gavinandresen@gmail.com>2013-09-08 17:48:42 -0700
committerGavin Andresen <gavinandresen@gmail.com>2013-09-08 17:48:42 -0700
commit4c723841e25650f045ed55b1e6a619d6d43398d5 (patch)
tree9686abff9919b504fe98b3027312459b4b496669 /src
parent8394f4a2dc77401529f441ea77246390bae1262c (diff)
parent55ed3f14751206fc87f0cbf8cb4e223efacef338 (diff)
downloadbitcoin-4c723841e25650f045ed55b1e6a619d6d43398d5.tar.xz
Merge pull request #2968 from TheBlueMatt/master
Don't warn about forks while fIsInitialDownload
Diffstat (limited to 'src')
-rw-r--r--src/main.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 24fd1fadbc..b708879f16 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1421,6 +1421,11 @@ CBlockIndex *pindexBestForkTip = NULL, *pindexBestForkBase = NULL;
void CheckForkWarningConditions()
{
+ // Before we get past initial download, we cannot reliably alert about forks
+ // (we assume we don't get stuck on a fork before the last checkpoint)
+ if (IsInitialBlockDownload())
+ return;
+
// If our best fork is no longer within 72 blocks (+/- 12 hours if no one mines it)
// of our head, drop it
if (pindexBestForkTip && nBestHeight - pindexBestForkTip->nHeight >= 72)