mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-05-28 04:52:36 +02:00
Qt/Options: Configure maxmempool using rwconf
This commit is contained in:
parent
04ac0eb698
commit
3d0f771518
@ -205,7 +205,7 @@ OptionsDialog::OptionsDialog(QWidget* parent, bool enableWallet)
|
|||||||
CreateOptionUI(verticalLayout_Mempool, maxorphantx, tr("Keep at most %s unconnected transactions in memory"));
|
CreateOptionUI(verticalLayout_Mempool, maxorphantx, tr("Keep at most %s unconnected transactions in memory"));
|
||||||
|
|
||||||
maxmempool = new QSpinBox(tabMempool);
|
maxmempool = new QSpinBox(tabMempool);
|
||||||
const int64_t nMempoolSizeMinMB = maxmempoolMinimumBytes(gArgs.GetIntArg("-limitdescendantsize", DEFAULT_DESCENDANT_SIZE_LIMIT_KVB) * 1'000);
|
const int64_t nMempoolSizeMinMB = maxmempoolMinimumBytes(gArgs.GetIntArg("-limitdescendantsize", DEFAULT_DESCENDANT_SIZE_LIMIT_KVB) * 1'000) / 1'000'000;
|
||||||
maxmempool->setMinimum(nMempoolSizeMinMB);
|
maxmempool->setMinimum(nMempoolSizeMinMB);
|
||||||
maxmempool->setMaximum(std::numeric_limits<int>::max());
|
maxmempool->setMaximum(std::numeric_limits<int>::max());
|
||||||
CreateOptionUI(verticalLayout_Mempool, maxmempool, tr("Keep the transaction memory pool below %s MB"));
|
CreateOptionUI(verticalLayout_Mempool, maxmempool, tr("Keep the transaction memory pool below %s MB"));
|
||||||
|
@ -613,7 +613,7 @@ QVariant OptionsModel::getOption(OptionID option, const std::string& suffix) con
|
|||||||
case maxorphantx:
|
case maxorphantx:
|
||||||
return qlonglong(gArgs.GetIntArg("-maxorphantx", DEFAULT_MAX_ORPHAN_TRANSACTIONS));
|
return qlonglong(gArgs.GetIntArg("-maxorphantx", DEFAULT_MAX_ORPHAN_TRANSACTIONS));
|
||||||
case maxmempool:
|
case maxmempool:
|
||||||
return qlonglong(node().mempool().m_max_size_bytes);
|
return qlonglong(node().mempool().m_max_size_bytes / 1'000'000);
|
||||||
default:
|
default:
|
||||||
return QVariant();
|
return QVariant();
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user