Changeset View
Changeset View
Standalone View
Standalone View
src/net.h
Show First 20 Lines • Show All 332 Lines • ▼ Show 20 Lines | void ForEachNodeThen(Callable &&pre, CallableAfter &&post) const { | ||||
} | } | ||||
} | } | ||||
post(); | post(); | ||||
}; | }; | ||||
// Addrman functions | // Addrman functions | ||||
void SetServices(const CService &addr, ServiceFlags nServices); | void SetServices(const CService &addr, ServiceFlags nServices); | ||||
void MarkAddressGood(const CAddress &addr); | void MarkAddressGood(const CAddress &addr); | ||||
void AddNewAddresses(const std::vector<CAddress> &vAddr, | bool AddNewAddresses(const std::vector<CAddress> &vAddr, | ||||
const CAddress &addrFrom, int64_t nTimePenalty = 0); | const CAddress &addrFrom, int64_t nTimePenalty = 0); | ||||
std::vector<CAddress> GetAddresses(size_t max_addresses, size_t max_pct); | std::vector<CAddress> GetAddresses(size_t max_addresses, size_t max_pct); | ||||
/** | /** | ||||
* Cache is used to minimize topology leaks, so it should | * Cache is used to minimize topology leaks, so it should | ||||
* be used for all non-trusted calls, for example, p2p. | * be used for all non-trusted calls, for example, p2p. | ||||
* A non-malicious call (from RPC or a peer with addr permission) should | * A non-malicious call (from RPC or a peer with addr permission) should | ||||
* call the function without a parameter to avoid using the cache. | * call the function without a parameter to avoid using the cache. | ||||
*/ | */ | ||||
▲ Show 20 Lines • Show All 1,013 Lines • Show Last 20 Lines |