diff options
author | brunoerg <brunoely.gc@gmail.com> | 2022-10-07 11:10:35 -0300 |
---|---|---|
committer | brunoerg <brunoely.gc@gmail.com> | 2023-05-26 13:38:22 -0300 |
commit | 7799eb125b7a1146f8251be5d26df574236212a9 (patch) | |
tree | 7ef87f84c198649e2e337f5cce00fc67bd84bd7b /src/test | |
parent | 5c1774a563dcc237a88df69569cd94fe81e908f7 (diff) |
p2p, refactor: return `std::vector<CNetAddr>` in `LookupHost`
Diffstat (limited to 'src/test')
-rw-r--r-- | src/test/fuzz/netbase_dns_lookup.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/test/fuzz/netbase_dns_lookup.cpp b/src/test/fuzz/netbase_dns_lookup.cpp index 81e216b358..a47c09b683 100644 --- a/src/test/fuzz/netbase_dns_lookup.cpp +++ b/src/test/fuzz/netbase_dns_lookup.cpp @@ -29,11 +29,9 @@ FUZZ_TARGET(netbase_dns_lookup) }; { - std::vector<CNetAddr> resolved_addresses; - if (LookupHost(name, resolved_addresses, max_results, allow_lookup, fuzzed_dns_lookup_function)) { - for (const CNetAddr& resolved_address : resolved_addresses) { - assert(!resolved_address.IsInternal()); - } + const std::vector<CNetAddr> resolved_addresses{LookupHost(name, max_results, allow_lookup, fuzzed_dns_lookup_function)}; + for (const CNetAddr& resolved_address : resolved_addresses) { + assert(!resolved_address.IsInternal()); } assert(resolved_addresses.size() <= max_results || max_results == 0); } |