Merge pull request #7330 from ethereum/fix-yuli-mload

Yul interpreter: Out of bounds mloads return zero
This commit is contained in:
chriseth 2019-09-03 11:20:21 +02:00 committed by GitHub
commit d1831b159d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -250,8 +250,7 @@ u256 EVMInstructionInterpreter::eval(
case Instruction::MLOAD:
if (accessMemory(arg[0], 0x20))
return readMemoryWord(arg[0]);
else
return 0x1234 + arg[0];
return 0;
case Instruction::MSTORE:
if (accessMemory(arg[0], 0x20))
writeMemoryWord(arg[0], arg[1]);