mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-06-19 21:31:37 +00:00
eth/ethconfig: update file gen_config.go (#1822)
This commit is contained in:
parent
8eb5fa7666
commit
52f682065a
1 changed files with 6 additions and 0 deletions
|
|
@ -27,6 +27,7 @@ func (c Config) MarshalTOML() (interface{}, error) {
|
|||
LightServ int `toml:",omitempty"`
|
||||
LightPeers int `toml:",omitempty"`
|
||||
SkipBcVersionCheck bool `toml:"-"`
|
||||
DeleteAllBadBlocks bool `toml:"-"`
|
||||
DatabaseHandles int `toml:"-"`
|
||||
DatabaseCache int
|
||||
TrieCleanCache int
|
||||
|
|
@ -56,6 +57,7 @@ func (c Config) MarshalTOML() (interface{}, error) {
|
|||
enc.LightServ = c.LightServ
|
||||
enc.LightPeers = c.LightPeers
|
||||
enc.SkipBcVersionCheck = c.SkipBcVersionCheck
|
||||
enc.DeleteAllBadBlocks = c.DeleteAllBadBlocks
|
||||
enc.DatabaseHandles = c.DatabaseHandles
|
||||
enc.DatabaseCache = c.DatabaseCache
|
||||
enc.TrieCleanCache = c.TrieCleanCache
|
||||
|
|
@ -89,6 +91,7 @@ func (c *Config) UnmarshalTOML(unmarshal func(interface{}) error) error {
|
|||
LightServ *int `toml:",omitempty"`
|
||||
LightPeers *int `toml:",omitempty"`
|
||||
SkipBcVersionCheck *bool `toml:"-"`
|
||||
DeleteAllBadBlocks *bool `toml:"-"`
|
||||
DatabaseHandles *int `toml:"-"`
|
||||
DatabaseCache *int
|
||||
TrieCleanCache *int
|
||||
|
|
@ -137,6 +140,9 @@ func (c *Config) UnmarshalTOML(unmarshal func(interface{}) error) error {
|
|||
if dec.SkipBcVersionCheck != nil {
|
||||
c.SkipBcVersionCheck = *dec.SkipBcVersionCheck
|
||||
}
|
||||
if dec.DeleteAllBadBlocks != nil {
|
||||
c.DeleteAllBadBlocks = *dec.DeleteAllBadBlocks
|
||||
}
|
||||
if dec.DatabaseHandles != nil {
|
||||
c.DatabaseHandles = *dec.DatabaseHandles
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue