MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / held_protocol

Function held_protocol

tests/test_coverage_children.c:232–251  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

230}
231
232static bool held_protocol(Child *child) {
233 if (child->operation >= EXEC_VE && child->operation <= EXEC_L) {
234 if (!expect_byte(child->ack[0], 'E'))
235 return false;
236 int marker = marker_present(child);
237 return marker >= 0 && note(child, "exec_held", marker, 0) && send_byte(child->gate[1], 'G');
238 }
239 if (child->operation == FAILED_EXEC) {
240 const char *stages[] = {"execve_failed", "execv_failed", "execvp_failed", "execl_failed"};
241 for (int i = 0; i < 4; i++) {
242 if (!expect_byte(child->ack[0], (char)('0' + i)))
243 return false;
244 int marker = marker_present(child);
245 if (marker < 0 || !note(child, stages[i], marker, ENOENT) ||
246 !send_byte(child->gate[1], 'G'))
247 return false;
248 }
249 }
250 return true;
251}
252
253static bool start_child(Child *child, const char *root) {
254 if (child->operation >= EXEC_VE && child->operation <= FAILED_EXEC &&

Callers 1

finish_childFunction · 0.85

Calls 4

expect_byteFunction · 0.85
send_byteFunction · 0.85
marker_presentFunction · 0.70
noteFunction · 0.70

Tested by

no test coverage detected