fixed crashing

This commit is contained in:
Evan Duffield 2014-11-28 18:37:26 -07:00
parent 8d0a7ea014
commit 2380c4169a

View File

@ -317,7 +317,7 @@ void ProcessConsensusVote(CConsensusVote& ctx)
void CleanTransactionLocksList() void CleanTransactionLocksList()
{ {
if(pindexBest == NULL) return; /* if(pindexBest == NULL) return;
std::map<uint256, CTransactionLock>::iterator it = mapTxLocks.begin(); std::map<uint256, CTransactionLock>::iterator it = mapTxLocks.begin();
@ -328,7 +328,7 @@ void CleanTransactionLocksList()
} }
++it; ++it;
} }
*/
} }
bool CConsensusVote::SignatureValid() bool CConsensusVote::SignatureValid()
@ -410,18 +410,18 @@ bool CTransactionLock::SignaturesValid()
if(n == -1) if(n == -1)
{ {
printf("InstantX::DoConsensusVote - Unknown Masternode\n"); LogPrintf("InstantX::DoConsensusVote - Unknown Masternode\n");
return false; return false;
} }
if(n > 10) if(n > 10)
{ {
printf("InstantX::DoConsensusVote - Masternode not in the top 10\n"); LogPrintf("InstantX::DoConsensusVote - Masternode not in the top 10\n");
return false; return false;
} }
if(!vote.SignatureValid()){ if(!vote.SignatureValid()){
printf("InstantX::CTransactionLock::SignaturesValid - Signature not valid\n"); LogPrintf("InstantX::CTransactionLock::SignaturesValid - Signature not valid\n");
return false; return false;
} }
} }