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

Method SendMessage

src/test/fuzz/p2p_headers_presync.cpp:87–100  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

85}
86
87void HeadersSyncSetup::SendMessage(FuzzedDataProvider& fuzzed_data_provider, CSerializedNetMsg&& msg)
88{
89 auto& connman = static_cast<ConnmanTestMsg&>(*m_node.connman);
90 CNode& connection = *PickValue(fuzzed_data_provider, m_connections);
91
92 connman.FlushSendBuffer(connection);
93 (void)connman.ReceiveMsgFrom(connection, std::move(msg));
94 connection.fPauseSend = false;
95 try {
96 connman.ProcessMessagesOnce(connection);
97 } catch (const std::ios_base::failure&) {
98 }
99 m_node.peerman->SendMessages(connection);
100}
101
102CBlockHeader ConsumeHeader(FuzzedDataProvider& fuzzed_data_provider, const uint256& prev_hash, uint32_t prev_nbits)
103{

Callers 1

Calls 3

FlushSendBufferMethod · 0.80
ReceiveMsgFromMethod · 0.80
SendMessagesMethod · 0.45

Tested by

no test coverage detected