mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-14 03:56:36 +00:00
cmd/utils: fix disabling cache preimages through config file (#33330)
This commit is contained in:
parent
5d51208334
commit
cd3f9b24e9
1 changed files with 3 additions and 2 deletions
|
|
@ -1683,8 +1683,9 @@ func SetEthConfig(ctx *cli.Context, stack *node.Node, cfg *ethconfig.Config) {
|
||||||
if ctx.IsSet(CacheNoPrefetchFlag.Name) {
|
if ctx.IsSet(CacheNoPrefetchFlag.Name) {
|
||||||
cfg.NoPrefetch = ctx.Bool(CacheNoPrefetchFlag.Name)
|
cfg.NoPrefetch = ctx.Bool(CacheNoPrefetchFlag.Name)
|
||||||
}
|
}
|
||||||
// Read the value from the flag no matter if it's set or not.
|
if ctx.IsSet(CachePreimagesFlag.Name) {
|
||||||
cfg.Preimages = ctx.Bool(CachePreimagesFlag.Name)
|
cfg.Preimages = ctx.Bool(CachePreimagesFlag.Name)
|
||||||
|
}
|
||||||
if cfg.NoPruning && !cfg.Preimages {
|
if cfg.NoPruning && !cfg.Preimages {
|
||||||
cfg.Preimages = true
|
cfg.Preimages = true
|
||||||
log.Info("Enabling recording of key preimages since archive mode is used")
|
log.Info("Enabling recording of key preimages since archive mode is used")
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue