|
|
@ -58,6 +58,7 @@ bool CCoinsViewDB::BatchWrite(const std::map<uint256, CCoins> &mapCoins, CBlockI |
|
|
|
CLevelDBBatch batch; |
|
|
|
CLevelDBBatch batch; |
|
|
|
for (std::map<uint256, CCoins>::const_iterator it = mapCoins.begin(); it != mapCoins.end(); it++) |
|
|
|
for (std::map<uint256, CCoins>::const_iterator it = mapCoins.begin(); it != mapCoins.end(); it++) |
|
|
|
BatchWriteCoins(batch, it->first, it->second); |
|
|
|
BatchWriteCoins(batch, it->first, it->second); |
|
|
|
|
|
|
|
if (pindex) |
|
|
|
BatchWriteHashBestChain(batch, pindex->GetBlockHash()); |
|
|
|
BatchWriteHashBestChain(batch, pindex->GetBlockHash()); |
|
|
|
|
|
|
|
|
|
|
|
return db.WriteBatch(batch); |
|
|
|
return db.WriteBatch(batch); |
|
|
|