Skip to content

Commit 45e8d66

Browse files
authored
Update SignatureChecker.sol
1 parent a05e964 commit 45e8d66

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

contracts/utils/cryptography/SignatureChecker.sol

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ pragma solidity ^0.8.24;
66
import {ECDSA} from "./ECDSA.sol";
77
import {IERC1271} from "../../interfaces/IERC1271.sol";
88
import {LowLevelCall} from "../LowLevelCall.sol";
9+
import {Memory} from "../Memory.sol";
910
import {IERC7913SignatureVerifier} from "../../interfaces/IERC7913.sol";
1011
import {Bytes} from "../../utils/Bytes.sol";
1112

@@ -51,8 +52,10 @@ library SignatureChecker {
5152
bytes32 hash,
5253
bytes memory signature
5354
) internal view returns (bool) {
55+
Memory.Pointer ptr = Memory.getFreeMemoryPointer();
5456
bytes memory params = abi.encodeCall(IERC1271.isValidSignature, (hash, signature));
5557
(bool success, bytes32 result, ) = LowLevelCall.staticcallReturn64Bytes(signer, params);
58+
Memory.setFreeMemoryPointer(ptr);
5659

5760
return success && LowLevelCall.returnDataSize() >= 32 && result == bytes32(IERC1271.isValidSignature.selector);
5861
}

0 commit comments

Comments
 (0)