aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2021-03-23 09:43:13 +0100
committerMarcoFalke <falke.marco@gmail.com>2021-03-23 09:43:15 +0100
commitd400e672a032e28f976332553b9a0e23d1927ae6 (patch)
tree6173e6afea3912789b2f8240ab81978c67a7ead8
parent1c3a8579c0a87cfb05a4090e50143cd932e9799e (diff)
parent55554463c15e3c75a64d26209dd3f8396e508cc2 (diff)
Merge #21487: fuzz: Use ConsumeWeakEnum in addrman for service flags
55554463c15e3c75a64d26209dd3f8396e508cc2 fuzz: Use ConsumeWeakEnum in addrman for service flags (MarcoFalke) Pull request description: This has minimally better performance. Reported by me in https://github.com/bitcoin/bitcoin/pull/20228#discussion_r598081787 ACKs for top commit: practicalswift: Tested ACK 55554463c15e3c75a64d26209dd3f8396e508cc2 vasild: ACK 55554463c15e3c75a64d26209dd3f8396e508cc2 Tree-SHA512: 4e5f51fe4f2bd7b2f37d0690e41203341ba45c0c9bc9247449cd26cfb5f77dc2ec61df3e4963276f68694e4b3ca3d0a76367a51c4d775501edeb3224d305a261
-rw-r--r--src/test/fuzz/addrman.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/fuzz/addrman.cpp b/src/test/fuzz/addrman.cpp
index b55f1c72b1..0baf30aef6 100644
--- a/src/test/fuzz/addrman.cpp
+++ b/src/test/fuzz/addrman.cpp
@@ -104,7 +104,7 @@ FUZZ_TARGET_INIT(addrman, initialize_addrman)
[&] {
const std::optional<CService> opt_service = ConsumeDeserializable<CService>(fuzzed_data_provider);
if (opt_service) {
- addr_man.SetServices(*opt_service, ServiceFlags{fuzzed_data_provider.ConsumeIntegral<uint64_t>()});
+ addr_man.SetServices(*opt_service, ConsumeWeakEnum(fuzzed_data_provider, ALL_SERVICE_FLAGS));
}
},
[&] {