Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/cyan-taxis-travel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'openzeppelin-solidity': minor
---

`Address`: bubble up revert data on `sendValue` failed call
4 changes: 2 additions & 2 deletions contracts/account/utils/draft-ERC4337Utils.sol
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ library ERC4337Utils {
return uint128(self.accountGasLimits.extract_32_16(0));
}

/// @dev Returns `accountGasLimits` from the {PackedUserOperation}.
/// @dev Returns `callGasLimit` from the {PackedUserOperation}.
function callGasLimit(PackedUserOperation calldata self) internal pure returns (uint256) {
return uint128(self.accountGasLimits.extract_32_16(16));
}
Expand Down Expand Up @@ -155,7 +155,7 @@ library ERC4337Utils {
return self.paymasterAndData.length < 52 ? 0 : uint128(bytes16(self.paymasterAndData[36:52]));
}

/// @dev Returns the forth section of `paymasterAndData` from the {PackedUserOperation}.
/// @dev Returns the fourth section of `paymasterAndData` from the {PackedUserOperation}.
function paymasterData(PackedUserOperation calldata self) internal pure returns (bytes calldata) {
return self.paymasterAndData.length < 52 ? _emptyCalldataBytes() : self.paymasterAndData[52:];
}
Expand Down
4 changes: 2 additions & 2 deletions contracts/interfaces/draft-IERC7579.sol
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ interface IERC7579Execution {
* MUST ensure adequate authorization control: e.g. onlyEntryPointOrSelf if used with ERC-4337
* If a mode is requested that is not supported by the Account, it MUST revert
*/
function execute(bytes32 mode, bytes calldata executionCalldata) external;
function execute(bytes32 mode, bytes calldata executionCalldata) external payable;

/**
* @dev Executes a transaction on behalf of the account.
Expand All @@ -136,7 +136,7 @@ interface IERC7579Execution {
function executeFromExecutor(
bytes32 mode,
bytes calldata executionCalldata
) external returns (bytes[] memory returnData);
) external payable returns (bytes[] memory returnData);
}

/**
Expand Down
4 changes: 2 additions & 2 deletions contracts/utils/Address.sol
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ library Address {
revert Errors.InsufficientBalance(address(this).balance, amount);
}

(bool success, ) = recipient.call{value: amount}("");
(bool success, bytes memory returndata) = recipient.call{value: amount}("");
if (!success) {
revert Errors.FailedCall();
_revert(returndata);
}
}

Expand Down
Loading