From 122549f6dee5f4d4daf7091d6302c38ba13ffb01 Mon Sep 17 00:00:00 2001 From: David Hill Date: Tue, 13 May 2014 16:38:36 -0400 Subject: Fix incorrect checkpoint data for testnet3 --- src/checkpoints.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/checkpoints.cpp') diff --git a/src/checkpoints.cpp b/src/checkpoints.cpp index 9ab8b6844..926949e06 100644 --- a/src/checkpoints.cpp +++ b/src/checkpoints.cpp @@ -66,8 +66,8 @@ namespace Checkpoints ; static const CCheckpointData dataTestnet = { &mapCheckpointsTestnet, - 1338180505, - 16341, + 1337966069, + 1488, 300 }; -- cgit v1.2.3 From 84ce18ca9339901f65d77a5821eb65f771316558 Mon Sep 17 00:00:00 2001 From: "Wladimir J. van der Laan" Date: Thu, 19 Jun 2014 15:10:04 +0200 Subject: Remove unnecessary dependencies for bitcoin-cli This commit removes all the unnecessary dependencies (key, core, netbase, sync, ...) from bitcoin-cli. To do this it shards the chain parameters into BaseParams, which contains just the RPC port and data directory (as used by utils and bitcoin-cli) and Params, with the rest. --- src/checkpoints.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/checkpoints.cpp') diff --git a/src/checkpoints.cpp b/src/checkpoints.cpp index 926949e06..75ac41891 100644 --- a/src/checkpoints.cpp +++ b/src/checkpoints.cpp @@ -83,9 +83,9 @@ namespace Checkpoints }; const CCheckpointData &Checkpoints() { - if (Params().NetworkID() == CChainParams::TESTNET) + if (Params().NetworkID() == CBaseChainParams::TESTNET) return dataTestnet; - else if (Params().NetworkID() == CChainParams::MAIN) + else if (Params().NetworkID() == CBaseChainParams::MAIN) return data; else return dataRegtest; -- cgit v1.2.3 From e10dcf27b4fb324a85b5650c7acd2ea5a52e822f Mon Sep 17 00:00:00 2001 From: Philip Kaufmann Date: Tue, 24 Jun 2014 14:17:43 +0200 Subject: ensure clean and consistent "namespace" usage - remove some missplaced ; - ensure end of a namespace is clearly visible - use same formatting when using namespace --- src/checkpoints.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/checkpoints.cpp') diff --git a/src/checkpoints.cpp b/src/checkpoints.cpp index 75ac41891..80479b47f 100644 --- a/src/checkpoints.cpp +++ b/src/checkpoints.cpp @@ -12,8 +12,8 @@ #include // for 'map_list_of()' #include -namespace Checkpoints -{ +namespace Checkpoints { + typedef std::map MapCheckpoints; // How many times we expect transactions after the last checkpoint to @@ -161,4 +161,5 @@ namespace Checkpoints } return NULL; } -} + +} // namespace Checkpoints -- cgit v1.2.3 From 209377a7cb5a9ea5d724faf94846ee5bacd289e7 Mon Sep 17 00:00:00 2001 From: jtimon Date: Sat, 28 Jun 2014 23:36:06 +0200 Subject: Use GetBlockTime() more --- src/checkpoints.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/checkpoints.cpp') diff --git a/src/checkpoints.cpp b/src/checkpoints.cpp index 80479b47f..4cab11db3 100644 --- a/src/checkpoints.cpp +++ b/src/checkpoints.cpp @@ -127,7 +127,7 @@ namespace Checkpoints { } else { double nCheapBefore = data.nTransactionsLastCheckpoint; double nExpensiveBefore = pindex->nChainTx - data.nTransactionsLastCheckpoint; - double nExpensiveAfter = (nNow - pindex->nTime)/86400.0*data.fTransactionsPerDay; + double nExpensiveAfter = (nNow - pindex->GetBlockTime())/86400.0*data.fTransactionsPerDay; fWorkBefore = nCheapBefore + nExpensiveBefore*fSigcheckVerificationFactor; fWorkAfter = nExpensiveAfter*fSigcheckVerificationFactor; } -- cgit v1.2.3