MCPcopy Create free account
hub / github.com/MayaPosch/NymphCast / verifyCallback

Function verifyCallback

src/test/test_databuffer_multi_port.cpp:133–148  ·  view source on GitHub ↗

--- VERIFY CALLBACK ---

Source from the content-addressed store, hash-verified

131
132// --- VERIFY CALLBACK ---
133void verifyCallback(uint8_t* buff, uint32_t len) {
134 for (uint32_t i = 0; i < len; ++i) {
135 if (buff[i] != readCnt++) {
136 std::cout << " === Data Check Fail ===" << std::endl;
137 std::cout << "Expected: " << (uint16_t) readCnt - 1 <<
138 ", got: " << (uint16_t) buff[i] << "." << std::endl;
139 std::cout << "\nSequence:" << std::endl;
140 std::cout.write((char*) buff, len);
141
142 // Exit.
143 gCon.signal();
144 }
145 }
146
147 std::cout << "\t PASS...";
148}
149
150
151void signal_handler(int signal) {

Callers

nothing calls this directly

Calls 1

writeMethod · 0.45

Tested by

no test coverage detected