Skip to content

Commit f09787a

Browse files
committed
check for empty accounts in code delegation processor
Signed-off-by: daniellehrner <[email protected]>
1 parent cd1fb99 commit f09787a

File tree

2 files changed

+293
-1
lines changed

2 files changed

+293
-1
lines changed

ethereum/core/src/main/java/org/hyperledger/besu/ethereum/mainnet/CodeDelegationProcessor.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,10 @@ private void processCodeDelegation(
126126

127127
MutableAccount authority;
128128
boolean authorityDoesAlreadyExist = false;
129-
if (maybeAuthorityAccount.isEmpty()) {
129+
130+
// we check for empty accounts as well in case we are on a chain that has still leftover empty
131+
// accounts after EIP-7523
132+
if (maybeAuthorityAccount.isEmpty() || maybeAuthorityAccount.get().isEmpty()) {
130133
// only create an account if nonce is valid
131134
if (codeDelegation.nonce() != 0) {
132135
return;

0 commit comments

Comments
 (0)