Skip to content

Commit 92a053b

Browse files
feat(event): skip log warning when solidity block number is 0
1 parent 8493819 commit 92a053b

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

framework/src/main/java/org/tron/core/db/Manager.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2119,8 +2119,10 @@ private void processTransactionTrigger(BlockCapsule newBlock) {
21192119
cumulativeLogCount += transactionInfo.getLogCount();
21202120
}
21212121
} else {
2122-
logger.error("PostBlockTrigger blockNum = {} has no transactions or {}.", newBlock.getNum(),
2123-
"the sizes of transactionInfoList and transactionCapsuleList are not equal");
2122+
if (newBlock.getNum() != 0) {
2123+
logger.error("PostBlockTrigger blockNum = {} has no transactions or {}.", newBlock.getNum(),
2124+
"the sizes of transactionInfoList and transactionCapsuleList are not equal");
2125+
}
21242126
for (TransactionCapsule e : newBlock.getTransactions()) {
21252127
postTransactionTrigger(e, newBlock);
21262128
}

0 commit comments

Comments
 (0)