Skip to content

Commit

Permalink
segmentation fault fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dusannosovic-ethernal committed Nov 27, 2023
1 parent 6d024b2 commit ddcc5c8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
18 changes: 9 additions & 9 deletions command/genesis/polybft_params.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,9 +169,6 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error {

chainConfig.Params.BurnContract = make(map[uint64]types.Address, 1)
chainConfig.Params.BurnContract[0] = types.ZeroAddress
chainConfig.Genesis.BaseFee = p.parsedBaseFeeConfig.baseFee
chainConfig.Genesis.BaseFeeEM = p.parsedBaseFeeConfig.baseFeeEM
chainConfig.Genesis.BaseFeeChangeDenom = p.parsedBaseFeeConfig.baseFeeChangeDenom

// deploy genesis contracts
allocs, err := p.deployContracts(rewardTokenByteCode, polyBftConfig, chainConfig)
Expand Down Expand Up @@ -215,12 +212,15 @@ func (p *genesisParams) generateChainConfig(o command.OutputFormatter) error {

// populate genesis parameters
chainConfig.Genesis = &chain.Genesis{
GasLimit: p.blockGasLimit,
Difficulty: 0,
Alloc: allocs,
ExtraData: genesisExtraData,
GasUsed: command.DefaultGenesisGasUsed,
Mixhash: polybft.PolyBFTMixDigest,
GasLimit: p.blockGasLimit,
Difficulty: 0,
Alloc: allocs,
ExtraData: genesisExtraData,
GasUsed: command.DefaultGenesisGasUsed,
Mixhash: polybft.PolyBFTMixDigest,
BaseFee: p.parsedBaseFeeConfig.baseFee,
BaseFeeEM: p.parsedBaseFeeConfig.baseFeeEM,
BaseFeeChangeDenom: p.parsedBaseFeeConfig.baseFeeChangeDenom,
}

if len(p.contractDeployerAllowListAdmin) != 0 {
Expand Down
2 changes: 1 addition & 1 deletion consensus/polybft/contracts_initializer.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ func initStakeManager(polyBFTConfig PolyBFTConfig, transition *state.Transition)
initFn := &contractsapi.InitializeStakeManagerFn{
GenesisValidators: startValidators,
NewStakingToken: contracts.NativeERC20TokenContract,
NewBls: polyBFTConfig.Bridge.BLSAddress,
NewBls: contracts.BLSContract,
EpochManager: contracts.EpochManagerContract,
NewDomain: signer.DomainValidatorSetString,
}
Expand Down

0 comments on commit ddcc5c8

Please sign in to comment.