Skip to content

Commit

Permalink
fixed bugs in post_execution.rs
Browse files Browse the repository at this point in the history
  • Loading branch information
BigBenlau committed May 2, 2024
1 parent 07789e9 commit 3ab0f28
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 0 additions & 1 deletion crates/primitives/src/result.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ pub enum ExecutionResult {
output: Output,
total_op_count: HashMap<String, u64>,
total_time: HashMap<String, u64>

},
/// Reverted by `REVERT` opcode that doesn't spend all gas.
Revert { gas_used: u64, output: Bytes },
Expand Down
4 changes: 3 additions & 1 deletion crates/revm/src/handler/mainnet/post_execution.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ use crate::{
},
Context, FrameResult,
};
use std::collections::HashMap;

/// Mainnet end handle does not change the output.
#[inline]
Expand Down Expand Up @@ -93,7 +94,8 @@ pub fn output<EXT, DB: Database>(
gas_refunded,
logs,
output,
..
total_op_count: HashMap::new(),
total_time: HashMap::new()
},
SuccessOrHalt::Revert => ExecutionResult::Revert {
gas_used: final_gas_used,
Expand Down

0 comments on commit 3ab0f28

Please sign in to comment.