diff options
| author | Ross Nicoll <[email protected]> | 2015-07-27 15:06:24 +0100 |
|---|---|---|
| committer | Ross Nicoll <[email protected]> | 2015-07-30 19:29:39 +0000 |
| commit | 3207dbf72830fb3ffa328d4fb25955d05e8e61ea (patch) | |
| tree | 48f56f0900bdd6b6e0baac64d892a99eb14653ed /src/init.cpp | |
| parent | Merge pull request #1207 from rnicoll/1.10-bitcoin (diff) | |
| download | discoin-3207dbf72830fb3ffa328d4fb25955d05e8e61ea.tar.xz discoin-3207dbf72830fb3ffa328d4fb25955d05e8e61ea.zip | |
Add chain height when fetching consensus parameters in initialization
Add chain height when fetching consensus parameters in initialization,
this code was missed in the first patch as it was disabled at the time.
Diffstat (limited to 'src/init.cpp')
| -rw-r--r-- | src/init.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/init.cpp b/src/init.cpp index a49406ec1..88a716a5a 100644 --- a/src/init.cpp +++ b/src/init.cpp @@ -1422,7 +1422,7 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler) StartNode(threadGroup, scheduler); // Monitor the chain, and alert if we get blocks much quicker or slower than expected - int64_t nPowTargetSpacing = Params().GetConsensus().nPowTargetSpacing; + int64_t nPowTargetSpacing = Params().GetConsensus(chainActive.Height()).nPowTargetSpacing; CScheduler::Function f = boost::bind(&PartitionCheck, &IsInitialBlockDownload, boost::ref(cs_main), boost::cref(pindexBestHeader), nPowTargetSpacing); scheduler.scheduleEvery(f, nPowTargetSpacing); |