diff --git a/src/libraries/PluginStorageLib.sol b/src/libraries/PluginStorageLib.sol index 949f78a2..e600561e 100644 --- a/src/libraries/PluginStorageLib.sol +++ b/src/libraries/PluginStorageLib.sol @@ -31,6 +31,8 @@ library PluginStorageLib { mstore(0x40, add(add(key, totalSize), 32)) mstore(key, totalSize) + // Clear any dirty upper bits of address + addr := and(addr, 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF) // Store the address and batch index in the key buffer mstore(add(key, 32), addr) mstore(add(key, 64), batchIndex)