MCPcopy Create free account
hub / github.com/bitcoin/bitcoin / NumToOpenSub

Method NumToOpenSub

src/net.cpp:3166–3174  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3164}
3165
3166size_t CConnman::PrivateBroadcast::NumToOpenSub(size_t n)
3167{
3168 size_t current_value{m_num_to_open.load()};
3169 size_t new_value;
3170 do {
3171 new_value = current_value > n ? current_value - n : 0;
3172 } while (!m_num_to_open.compare_exchange_strong(current_value, new_value));
3173 return new_value;
3174}
3175
3176void CConnman::PrivateBroadcast::NumToOpenWait() const
3177{

Callers 3

AbortPrivateBroadcastMethod · 0.80
ProcessMessageMethod · 0.80

Calls 1

loadMethod · 0.45

Tested by

no test coverage detected