tx_pool: fix divide by 0 in log

Coverity 205394
This commit is contained in:
moneromooo-monero 2019-10-25 16:56:55 +00:00
parent cc46f05f1f
commit 174a6ac9c5
No known key found for this signature in database
GPG key ID: 686F07454D6CEFC3

View file

@ -324,7 +324,7 @@ namespace cryptonote
++m_cookie; ++m_cookie;
MINFO("Transaction added to pool: txid " << id << " weight: " << tx_weight << " fee/byte: " << (fee / (double)tx_weight)); MINFO("Transaction added to pool: txid " << id << " weight: " << tx_weight << " fee/byte: " << (fee / (double)(tx_weight ? tx_weight : 1)));
prune(m_txpool_max_weight); prune(m_txpool_max_weight);