diff options
-rw-r--r-- | src/cryptonote_core/cryptonote_core.cpp | 12 | ||||
-rw-r--r-- | src/cryptonote_core/tx_pool.cpp | 4 |
2 files changed, 12 insertions, 4 deletions
diff --git a/src/cryptonote_core/cryptonote_core.cpp b/src/cryptonote_core/cryptonote_core.cpp index 64c14f7a2..e0430a18a 100644 --- a/src/cryptonote_core/cryptonote_core.cpp +++ b/src/cryptonote_core/cryptonote_core.cpp @@ -137,7 +137,12 @@ namespace cryptonote }; static const command_line::arg_descriptor<bool> arg_fluffy_blocks = { "fluffy-blocks" - , "Relay blocks as fluffy blocks where possible (automatic on testnet)" + , "Relay blocks as fluffy blocks (obsolete, now default)" + , true + }; + static const command_line::arg_descriptor<bool> arg_no_fluffy_blocks = { + "no-fluffy-blocks" + , "Relay blocks as normal blocks" , false }; static const command_line::arg_descriptor<size_t> arg_max_txpool_size = { @@ -245,6 +250,7 @@ namespace cryptonote command_line::add_arg(desc, arg_block_sync_size); command_line::add_arg(desc, arg_check_updates); command_line::add_arg(desc, arg_fluffy_blocks); + command_line::add_arg(desc, arg_no_fluffy_blocks); command_line::add_arg(desc, arg_test_dbg_lock_sleep); command_line::add_arg(desc, arg_offline); command_line::add_arg(desc, arg_disable_dns_checkpoints); @@ -280,9 +286,11 @@ namespace cryptonote set_enforce_dns_checkpoints(command_line::get_arg(vm, arg_dns_checkpoints)); test_drop_download_height(command_line::get_arg(vm, arg_test_drop_download_height)); - m_fluffy_blocks_enabled = m_testnet || get_arg(vm, arg_fluffy_blocks); + m_fluffy_blocks_enabled = !get_arg(vm, arg_no_fluffy_blocks); m_offline = get_arg(vm, arg_offline); m_disable_dns_checkpoints = get_arg(vm, arg_disable_dns_checkpoints); + if (!command_line::is_arg_defaulted(vm, arg_fluffy_blocks)) + MWARNING(arg_fluffy_blocks.name << " is obsolete, it is now default"); if (command_line::get_arg(vm, arg_test_drop_download) == true) test_drop_download(); diff --git a/src/cryptonote_core/tx_pool.cpp b/src/cryptonote_core/tx_pool.cpp index 5f54e93f1..762feb5ee 100644 --- a/src/cryptonote_core/tx_pool.cpp +++ b/src/cryptonote_core/tx_pool.cpp @@ -181,7 +181,7 @@ namespace cryptonote } size_t tx_size_limit = get_transaction_size_limit(version); - if (!kept_by_block && blob_size >= tx_size_limit) + if (!kept_by_block && blob_size > tx_size_limit) { LOG_PRINT_L1("transaction is too big: " << blob_size << " bytes, maximum size: " << tx_size_limit); tvc.m_verifivation_failed = true; @@ -1207,7 +1207,7 @@ namespace cryptonote m_txpool_size = 0; m_blockchain.for_all_txpool_txes([this, &remove, tx_size_limit](const crypto::hash &txid, const txpool_tx_meta_t &meta, const cryptonote::blobdata*) { m_txpool_size += meta.blob_size; - if (meta.blob_size >= tx_size_limit) { + if (meta.blob_size > tx_size_limit) { LOG_PRINT_L1("Transaction " << txid << " is too big (" << meta.blob_size << " bytes), removing it from pool"); remove.insert(txid); } |