From f0cc349333d3790e10ef3c501d5beffd007e9338 Mon Sep 17 00:00:00 2001 From: Nick Savers Date: Tue, 16 Sep 2014 01:50:01 +0200 Subject: [PATCH] Add memsize calculation for EXTCODECOPY --- libevm/VM.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/libevm/VM.h b/libevm/VM.h index e7d218ec6..a07e225e6 100644 --- a/libevm/VM.h +++ b/libevm/VM.h @@ -157,7 +157,11 @@ template dev::bytesConstRef dev::eth::VM::go(Ext& _ext, OnOpFunc con require(3); newTempSize = memNeed(m_stack.back(), m_stack[m_stack.size() - 3]); break; - + case Instruction::EXTCODECOPY: + require(4); + newTempSize = memNeed(m_stack[m_stack.size() - 2], m_stack[m_stack.size() - 4]); + break; + case Instruction::BALANCE: runGas = c_balanceGas; break;