diff --git a/ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/rlpx/wire/messages/EmptyMessage.java b/ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/rlpx/wire/messages/EmptyMessage.java index 4611dc4b207..639f486df44 100644 --- a/ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/rlpx/wire/messages/EmptyMessage.java +++ b/ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/rlpx/wire/messages/EmptyMessage.java @@ -14,6 +14,8 @@ */ package org.hyperledger.besu.ethereum.p2p.rlpx.wire.messages; +import static org.hyperledger.besu.ethereum.rlp.RLP.EMPTY_LIST; + import org.hyperledger.besu.ethereum.p2p.rlpx.wire.MessageData; import org.apache.tuweni.bytes.Bytes; @@ -23,12 +25,12 @@ abstract class EmptyMessage implements MessageData { @Override public final int getSize() { - return 0; + return EMPTY_LIST.size(); } @Override public Bytes getData() { - return Bytes.EMPTY; + return EMPTY_LIST; } @Override