mirror of
https://github.com/status-im/ethereumj-personal.git
synced 2025-02-13 12:16:23 +00:00
Fix bug where nonce was treated for RLP conversion as byte array when it is in fact a number
This commit is contained in:
parent
02c6f9c2aa
commit
ebd13f8e9e
@ -60,7 +60,7 @@ public class HashUtil {
|
||||
public static byte[] calcNewAddr(byte[] addr, byte[] nonce) {
|
||||
|
||||
byte[] encSender = RLP.encodeElement(addr);
|
||||
byte[] encNonce = RLP.encodeElement(nonce);
|
||||
byte[] encNonce = RLP.encodeBigInteger(new BigInteger(1, nonce));
|
||||
byte[] newAddress = sha3omit12(RLP.encodeList(encSender, encNonce));
|
||||
|
||||
return newAddress;
|
||||
|
Loading…
x
Reference in New Issue
Block a user