Browse Source

Merge pull request #2526 from arkpar/state

Fixed call to contract from rpc
cl-refactor
Gav Wood 10 years ago
parent
commit
859f6d0ff7
  1. 11
      libethereum/Executive.cpp

11
libethereum/Executive.cpp

@ -399,11 +399,14 @@ void Executive::finalize()
m_refunded = m_ext ? min((m_t.gas() - m_gas) / 2, m_ext->sub.refunds) : 0;
m_gas += m_refunded;
// cnote << "Refunding" << formatBalance(m_endGas * m_ext->gasPrice) << "to origin (=" << m_endGas << "*" << formatBalance(m_ext->gasPrice) << ")";
m_s.addBalance(m_t.sender(), m_gas * m_t.gasPrice());
if (m_t)
{
// cnote << "Refunding" << formatBalance(m_endGas * m_ext->gasPrice) << "to origin (=" << m_endGas << "*" << formatBalance(m_ext->gasPrice) << ")";
m_s.addBalance(m_t.sender(), m_gas * m_t.gasPrice());
u256 feesEarned = (m_t.gas() - m_gas) * m_t.gasPrice();
m_s.addBalance(m_s.m_currentBlock.coinbaseAddress(), feesEarned);
u256 feesEarned = (m_t.gas() - m_gas) * m_t.gasPrice();
m_s.addBalance(m_s.m_currentBlock.coinbaseAddress(), feesEarned);
}
// Suicides...
if (m_ext)

Loading…
Cancel
Save