core, core/types: refactored tx chain id checking (#3257)
* core, core/types: refactored tx chain id checking Refactored explicit chain id checking in to the Sender deriviation method * cmd/utils, params: define chain ids
This commit is contained in:
		| @@ -906,6 +906,13 @@ func MakeChainConfigFromDb(ctx *cli.Context, db ethdb.Database) *params.ChainCon | ||||
| 				config.EIP158Block = params.MainNetSpuriousDragon | ||||
| 			} | ||||
| 		} | ||||
| 		if config.ChainId.BitLen() == 0 { | ||||
| 			if ctx.GlobalBool(TestNetFlag.Name) { | ||||
| 				config.ChainId = params.TestNetChainID | ||||
| 			} else { | ||||
| 				config.ChainId = params.MainNetChainID | ||||
| 			} | ||||
| 		} | ||||
| 		config.DAOForkSupport = true | ||||
| 	} | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user