mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-24 21:56:43 +00:00
Apply suggestions from code review
Signed-off-by: jsvisa <delweng@gmail.com>
This commit is contained in:
parent
d5da02a430
commit
525aacbb53
2 changed files with 2 additions and 2 deletions
|
|
@ -60,7 +60,7 @@ var Defaults = Config{
|
||||||
TrieCleanCache: 154,
|
TrieCleanCache: 154,
|
||||||
TrieDirtyCache: 256,
|
TrieDirtyCache: 256,
|
||||||
TrieTimeout: 60 * time.Minute,
|
TrieTimeout: 60 * time.Minute,
|
||||||
TrieDBJournal: "triedb.journal",
|
TrieDBJournal: "triedb.journal.rlp",
|
||||||
SnapshotCache: 102,
|
SnapshotCache: 102,
|
||||||
FilterLogCacheSize: 32,
|
FilterLogCacheSize: 32,
|
||||||
Miner: miner.DefaultConfig,
|
Miner: miner.DefaultConfig,
|
||||||
|
|
|
||||||
|
|
@ -344,7 +344,7 @@ func (db *Database) Journal(root common.Hash) error {
|
||||||
var err error
|
var err error
|
||||||
file, err = os.OpenFile(tmpName, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644)
|
file, err = os.OpenFile(tmpName, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0644)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return fmt.Errorf("failed to open journal file %s: %w", db.config.JournalPath, err)
|
return fmt.Errorf("failed to open journal file %s: %w", tmpName, err)
|
||||||
}
|
}
|
||||||
defer func() {
|
defer func() {
|
||||||
if file != nil {
|
if file != nil {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue