EIP-2929: add tx sender and address into the access list
This commit is contained in:
parent
aa41520dd1
commit
0fd7c59724
@ -1145,6 +1145,7 @@ impl<'a, B: 'a + StateBackend> Executive<'a, B> {
|
||||
let mut access_list = AccessList::new(schedule.eip2929);
|
||||
|
||||
if schedule.eip2929 {
|
||||
access_list.insert_address(sender);
|
||||
for (address, builtin) in self.machine.builtins() {
|
||||
if builtin.is_active(self.info.number) {
|
||||
access_list.insert_address(*address);
|
||||
@ -1234,6 +1235,7 @@ impl<'a, B: 'a + StateBackend> Executive<'a, B> {
|
||||
&nonce,
|
||||
&t.tx().data,
|
||||
);
|
||||
access_list.insert_address(new_address);
|
||||
let params = ActionParams {
|
||||
code_address: new_address.clone(),
|
||||
code_hash: code_hash,
|
||||
@ -1257,6 +1259,7 @@ impl<'a, B: 'a + StateBackend> Executive<'a, B> {
|
||||
(res, out)
|
||||
}
|
||||
Action::Call(ref address) => {
|
||||
access_list.insert_address(address.clone());
|
||||
let params = ActionParams {
|
||||
code_address: address.clone(),
|
||||
address: address.clone(),
|
||||
|
Loading…
Reference in New Issue
Block a user