mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-17 10:20:44 +00:00
parent
f552cebfcd
commit
cf5766177a
1 changed files with 0 additions and 6 deletions
|
|
@ -686,12 +686,6 @@ func (db *Database) Commit(node common.Hash, report bool) error {
|
||||||
// Move all of the accumulated preimages into a write batch
|
// Move all of the accumulated preimages into a write batch
|
||||||
if db.preimages != nil {
|
if db.preimages != nil {
|
||||||
rawdb.WritePreimages(batch, db.preimages)
|
rawdb.WritePreimages(batch, db.preimages)
|
||||||
if batch.ValueSize() > ethdb.IdealBatchSize {
|
|
||||||
if err := batch.Write(); err != nil {
|
|
||||||
return err
|
|
||||||
}
|
|
||||||
batch.Reset()
|
|
||||||
}
|
|
||||||
// Since we're going to replay trie Node writes into the clean Cache, flush out
|
// Since we're going to replay trie Node writes into the clean Cache, flush out
|
||||||
// any batched pre-images before continuing.
|
// any batched pre-images before continuing.
|
||||||
if err := batch.Write(); err != nil {
|
if err := batch.Write(); err != nil {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue