Fix: ledger bootstrap_weights size is reported as 0 (#3978)

This commit is contained in:
Gustav Schauwecker 2022-10-24 12:31:55 +02:00 committed by GitHub
commit 4df1109d17
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 1 additions and 2 deletions

View file

@ -1605,7 +1605,7 @@ nano::uncemented_info::uncemented_info (nano::block_hash const & cemented_fronti
std::unique_ptr<nano::container_info_component> nano::collect_container_info (ledger & ledger, std::string const & name)
{
auto count = ledger.bootstrap_weights_size.load ();
auto count = ledger.bootstrap_weights.size ();
auto sizeof_element = sizeof (decltype (ledger.bootstrap_weights)::value_type);
auto composite = std::make_unique<container_info_composite> (name);
composite->add_component (std::make_unique<container_info_leaf> (container_info{ "bootstrap_weights", count, sizeof_element }));

View file

@ -77,7 +77,6 @@ public:
nano::ledger_cache cache;
nano::stat & stats;
std::unordered_map<nano::account, nano::uint128_t> bootstrap_weights;
std::atomic<size_t> bootstrap_weights_size{ 0 };
uint64_t bootstrap_weight_max_blocks{ 1 };
std::atomic<bool> check_bootstrap_weights;
bool pruning{ false };