Commit 5005da9a authored by Kelvin Fichter's avatar Kelvin Fichter

fix(l2g): bug in state dumper

Fixes a bug in the state dumper. os.OpenFile was using the wrong file
descriptors and that would break l2geth.
parent 3ba67555
---
'@eth-optimism/l2geth': patch
---
Fixes a small l2geth bug when trying to dump state
......@@ -2,10 +2,11 @@ package statedumper
import (
"fmt"
"github.com/ethereum-optimism/optimism/l2geth/common"
"io"
"os"
"sync"
"github.com/ethereum-optimism/optimism/l2geth/common"
)
type StateDumper interface {
......@@ -21,7 +22,7 @@ func NewStateDumper() StateDumper {
return &noopStateDumper{}
}
f, err := os.OpenFile(path, os.O_APPEND|os.O_CREATE, 0o755)
f, err := os.OpenFile(path, os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0o755)
if err != nil {
panic(err)
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment