From b1333a6c0718080ea20cd215708b4c5f6102f56f Mon Sep 17 00:00:00 2001 From: Danno Ferrin Date: Tue, 24 Sep 2024 13:48:42 -0600 Subject: [PATCH] Change evmtool eof-test handling of empty code In EOFTest, treat empty code as invalid. Signed-off-by: Danno Ferrin --- .../java/org/hyperledger/besu/evmtool/EOFTestSubCommand.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ethereum/evmtool/src/main/java/org/hyperledger/besu/evmtool/EOFTestSubCommand.java b/ethereum/evmtool/src/main/java/org/hyperledger/besu/evmtool/EOFTestSubCommand.java index 94f8b2cd492..fb28701f777 100644 --- a/ethereum/evmtool/src/main/java/org/hyperledger/besu/evmtool/EOFTestSubCommand.java +++ b/ethereum/evmtool/src/main/java/org/hyperledger/besu/evmtool/EOFTestSubCommand.java @@ -224,7 +224,7 @@ public TestResult considerCode(final String hexCode) { return failed(re.getMessage()); } if (codeBytes.isEmpty()) { - return passed(); + return failed("invalid_magic code is zero-length"); } var layout = EOFLayout.parseEOF(codeBytes);