Skip to content

Commit

Permalink
build fix (2)
Browse files Browse the repository at this point in the history
  • Loading branch information
valdok committed Jun 29, 2023
1 parent 594e218 commit 18e765d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
8 changes: 6 additions & 2 deletions bvm/evm.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -973,12 +973,16 @@ OnOpcode(Create2)
Address aNew;
{
KeccakProcessor<Word::nBits> hp;

uint8_t n = 0xff;
hp.Write(&n, sizeof(n));
hp << get_Caller(p).ToWord();
hp << wSalt;

Word wRes;
get_Caller(p).ToWord(wRes);

hp << wRes;
hp << wSalt;

hp >> wRes;
aNew = Address::W2A(wRes);
}
Expand Down
1 change: 0 additions & 1 deletion core/keccak.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ namespace beam
static const uint32_t nWordsBlock = nSizeBlock / nSizeWord;

KeccakProcessor()
:m_LastWordBytes(0) // workaround, otherwise compiler with optimizations produces an out-of-bounds error/warning
{
ZeroObject(*this);

Expand Down

0 comments on commit 18e765d

Please sign in to comment.