diff options
author | s_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b> | 2010-08-16 18:46:02 +0000 |
---|---|---|
committer | s_nakamoto <s_nakamoto@1a98c847-1fd6-4fd8-948a-caf3550aa51b> | 2010-08-16 18:46:02 +0000 |
commit | 44a0de1861a78a693ad3331f0f7b06003a78a9d7 (patch) | |
tree | d45c08f097bb8862e5114b99a9229b85ec7d469b /main.cpp | |
parent | a01d5876fa6a9a9fe28cff3ad3ed0e91d5612125 (diff) |
do an extra CheckBlock in ConnectBlock
git-svn-id: https://bitcoin.svn.sourceforge.net/svnroot/bitcoin/trunk@139 1a98c847-1fd6-4fd8-948a-caf3550aa51b
Diffstat (limited to 'main.cpp')
-rw-r--r-- | main.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -1107,6 +1107,10 @@ bool CBlock::DisconnectBlock(CTxDB& txdb, CBlockIndex* pindex) bool CBlock::ConnectBlock(CTxDB& txdb, CBlockIndex* pindex)
{
+ // Check it again in case a previous version let a bad block in
+ if (!CheckBlock())
+ return false;
+
//// issue here: it doesn't know the version
unsigned int nTxPos = pindex->nBlockPos + ::GetSerializeSize(CBlock(), SER_DISK) - 1 + GetSizeOfCompactSize(vtx.size());
|