From cfa5f09016f4de72a00fcdcdd4b7819f9b2e3b44 Mon Sep 17 00:00:00 2001 From: tgmichel Date: Tue, 30 May 2023 15:19:06 +0200 Subject: [PATCH 1/2] Prevent exiting substate on top level create function --- src/executor/stack/executor.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/executor/stack/executor.rs b/src/executor/stack/executor.rs index 4d30981d5..acc556345 100644 --- a/src/executor/stack/executor.rs +++ b/src/executor/stack/executor.rs @@ -435,7 +435,6 @@ impl<'config, 'precompiles, S: StackState<'config>, P: PrecompileSet> if let Some(limit) = self.config.max_initcode_size { if init_code.len() > limit { self.state.metadata_mut().gasometer.fail(); - let _ = self.exit_substate(StackExitKind::Failed); return emit_exit!(ExitError::CreateContractLimit.into(), Vec::new()); } } From e822a2a286808367b27930c7e811ffe77888ce81 Mon Sep 17 00:00:00 2001 From: tgmichel Date: Tue, 30 May 2023 15:37:35 +0200 Subject: [PATCH 2/2] `transact_create2` --- src/executor/stack/executor.rs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/executor/stack/executor.rs b/src/executor/stack/executor.rs index acc556345..869296a64 100644 --- a/src/executor/stack/executor.rs +++ b/src/executor/stack/executor.rs @@ -475,7 +475,6 @@ impl<'config, 'precompiles, S: StackState<'config>, P: PrecompileSet> if let Some(limit) = self.config.max_initcode_size { if init_code.len() > limit { self.state.metadata_mut().gasometer.fail(); - let _ = self.exit_substate(StackExitKind::Failed); return emit_exit!(ExitError::CreateContractLimit.into(), Vec::new()); } }