Browse Source

Updates to contract creation code.

cl-refactor
Gav Wood 11 years ago
parent
commit
52bb88b88a
  1. 10
      libethereum/State.cpp

10
libethereum/State.cpp

@ -916,16 +916,10 @@ h160 State::create(Address _sender, u256 _endowment, u256 _gasPrice, u256* _gas,
if (revert)
evm.revert();
// Kill contract if there's no code.
if (out.empty())
{
m_cache.erase(newAddress);
newAddress = Address();
}
else
// Set code as long as we didn't suicide.
if (addressInUse(newAddress))
m_cache[newAddress].setCode(out);
*_gas = vm.gas();
return newAddress;

Loading…
Cancel
Save