git://git.novaco.in
/
novacoin.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
58ddfd2
)
Revert GetBlockTrust changes
author
alex
<alex@alex-VirtualBox.(none)>
Sat, 28 Sep 2013 17:56:25 +0000 (21:56 +0400)
committer
alex
<alex@alex-VirtualBox.(none)>
Sat, 28 Sep 2013 17:56:25 +0000 (21:56 +0400)
src/main.cpp
patch
|
blob
|
history
diff --git
a/src/main.cpp
b/src/main.cpp
index
19f7992
..
68190ad
100644
(file)
--- a/
src/main.cpp
+++ b/
src/main.cpp
@@
-2294,6
+2294,12
@@
uint256 CBlockIndex::GetBlockTrust() const
if (bnTarget <= 0)
return 0;
+ /* Old protocol */
+ if (!fTestNet && GetBlockTime() < CHAINCHECKS_SWITCH_TIME)
+ return (IsProofOfStake()? ((CBigNum(1)<<256) / (bnTarget+1)).getuint256() : 1);
+
+ /* New protocol */
+
// Calculate work amount for block
uint256 nPoWTrust = (CBigNum(nPoWBase) / (bnTarget+1)).getuint256();