mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-19 03:10:48 +00:00
core/txpool: fix the same issue in setupWriter
This commit is contained in:
parent
a87a74f645
commit
48c5e29874
1 changed files with 3 additions and 2 deletions
|
|
@ -119,10 +119,11 @@ func (journal *journal) load(add func([]*types.Transaction) []error) error {
|
|||
|
||||
func (journal *journal) setupWriter() error {
|
||||
if journal.writer != nil {
|
||||
if err := journal.writer.Close(); err != nil {
|
||||
err := journal.writer.Close()
|
||||
journal.writer = nil
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
journal.writer = nil
|
||||
}
|
||||
|
||||
// Re-open the journal file for appending
|
||||
|
|
|
|||
Loading…
Reference in a new issue