From f572f2b2048994b3b50f4cfd5de19e40b1acfb22 Mon Sep 17 00:00:00 2001 From: John Newbery Date: Tue, 24 Aug 2021 11:27:05 +0100 Subject: [addrman] Set m_asmap in CAddrMan initializer list This allows us to make it const. --- src/bench/addrman.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/bench') diff --git a/src/bench/addrman.cpp b/src/bench/addrman.cpp index d69a651811..8fbb68c04c 100644 --- a/src/bench/addrman.cpp +++ b/src/bench/addrman.cpp @@ -73,14 +73,14 @@ static void AddrManAdd(benchmark::Bench& bench) CreateAddresses(); bench.run([&] { - CAddrMan addrman{/* deterministic */ false, /* consistency_check_ratio */ 0}; + CAddrMan addrman{/* asmap */ std::vector(), /* deterministic */ false, /* consistency_check_ratio */ 0}; AddAddressesToAddrMan(addrman); }); } static void AddrManSelect(benchmark::Bench& bench) { - CAddrMan addrman(/* deterministic */ false, /* consistency_check_ratio */ 0); + CAddrMan addrman(/* asmap */ std::vector(), /* deterministic */ false, /* consistency_check_ratio */ 0); FillAddrMan(addrman); @@ -92,7 +92,7 @@ static void AddrManSelect(benchmark::Bench& bench) static void AddrManGetAddr(benchmark::Bench& bench) { - CAddrMan addrman(/* deterministic */ false, /* consistency_check_ratio */ 0); + CAddrMan addrman(/* asmap */ std::vector(), /* deterministic */ false, /* consistency_check_ratio */ 0); FillAddrMan(addrman); @@ -114,7 +114,7 @@ static void AddrManGood(benchmark::Bench& bench) std::vector> addrmans(addrman_count); for (size_t i{0}; i < addrman_count; ++i) { - addrmans[i] = std::make_unique(/* deterministic */ false, /* consistency_check_ratio */ 0); + addrmans[i] = std::make_unique(/* asmap */ std::vector(), /* deterministic */ false, /* consistency_check_ratio */ 0); FillAddrMan(*addrmans[i]); } -- cgit v1.2.3