core: don't overwrite the precompiled account

Signed-off-by: jsvisa <delweng@gmail.com>
This commit is contained in:
jsvisa 2023-09-11 18:02:49 +08:00
parent d64f42d452
commit 39206842f2

View file

@ -613,9 +613,12 @@ func DeveloperGenesisBlock(gasLimit uint64, faucet common.Address, genesisAlloc
if genesisAlloc != nil {
for addr, account := range *genesisAlloc {
// Don't overwrite the precompiled accounts
if _, ok := alloc[addr]; !ok {
alloc[addr] = account
}
}
}
// Assemble and return the genesis with the precompiles and faucet pre-funded
return &Genesis{