Merge pull request #13001 from matheusaaguiar/develop

Don't add an empty data slot to ABI-encoded empty strings from storage
This commit is contained in:
chriseth
2022-05-23 10:56:30 +02:00
committed by GitHub
10 changed files with 110 additions and 9 deletions
+1 -1
View File
@@ -699,7 +699,7 @@ string ABIFunctions::abiEncodingFunctionCompactStorageArray(
case 0 {
// short byte array
mstore(pos, and(slotValue, not(0xff)))
ret := add(pos, <lengthPaddedShort>)
ret := add(pos, mul(<lengthPaddedShort>, iszero(iszero(length))))
}
case 1 {
// long byte array