Browse Source

Increment nonce for creation from code.

cl-refactor
Gav Wood 11 years ago
parent
commit
475cd02517
  1. 2
      alethzero/MainWin.cpp
  2. 1
      libethereum/Instruction.cpp
  3. 3
      libethereum/State.h

2
alethzero/MainWin.cpp

@ -506,7 +506,7 @@ void Main::on_data_textChanged()
}
else
{
string code = ui->data->toPlainText().replace(" ", "").toStdString();
string code = ui->data->toPlainText().replace(" ", "").replace("\n", "").replace("\t", "").toStdString();
try
{
m_data = fromHex(code);

1
libethereum/Instruction.cpp

@ -529,7 +529,6 @@ static int compileLispFragment(char const*& d, char const* e, bool _quiet, bytes
return false;
unsigned startLocation = (unsigned)o_code.size();
o_locs.push_back(startLocation);
// First fragment - predicate
appendCode(o_code, o_locs, codes[0], locs[0]);

3
libethereum/State.h

@ -275,6 +275,9 @@ public:
h160 create(u256 _endowment, u256* _gas, bytesConstRef _code, bytesConstRef _init)
{
// Increment associated nonce for sender.
m_s.noteSending(myAddress);
return m_s.create(myAddress, _endowment, gasPrice, _gas, _code, _init);
}

Loading…
Cancel
Save