shrink_to_fit after removing hashes.
This commit is contained in:
parent
c4333461bb
commit
dadc2a96ea
@ -759,6 +759,14 @@ impl BlockChain {
|
||||
|
||||
// TODO: handle block_hashes properly.
|
||||
block_hashes.clear();
|
||||
|
||||
blocks.shrink_to_fit();
|
||||
block_details.shrink_to_fit();
|
||||
block_hashes.shrink_to_fit();
|
||||
transaction_addresses.shrink_to_fit();
|
||||
block_logs.shrink_to_fit();
|
||||
blocks_blooms.shrink_to_fit();
|
||||
block_receipts.shrink_to_fit();
|
||||
}
|
||||
if self.cache_size().total() < self.max_cache_size { break; }
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user