MCPcopy Create free account
hub / github.com/ElementsProject/elements / Wait

Method Wait

src/test/fuzz/util.cpp:196–211  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

194}
195
196bool FuzzedSock::Wait(std::chrono::milliseconds timeout, Event requested, Event* occurred) const
197{
198 constexpr std::array wait_errnos{
199 EBADF,
200 EINTR,
201 EINVAL,
202 };
203 if (m_fuzzed_data_provider.ConsumeBool()) {
204 SetFuzzedErrNo(m_fuzzed_data_provider, wait_errnos);
205 return false;
206 }
207 if (occurred != nullptr) {
208 *occurred = m_fuzzed_data_provider.ConsumeBool() ? requested : 0;
209 }
210 return true;
211}
212
213bool FuzzedSock::IsConnected(std::string& errmsg) const
214{

Callers 5

Correct_Queue_rangeFunction · 0.45
BOOST_AUTO_TEST_CASEFunction · 0.45
BOOST_AUTO_TEST_CASEFunction · 0.45
BOOST_AUTO_TEST_CASEFunction · 0.45
FUZZ_TARGETFunction · 0.45

Calls 2

SetFuzzedErrNoFunction · 0.85
ConsumeBoolMethod · 0.80

Tested by

no test coverage detected