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

Function search_root_fixture_destroy

tests/test_mcp.c:24346–24356  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24344}
24345
24346static void search_root_fixture_destroy(search_root_fixture_t *fx) {
24347 /* Unlink the links first so the tree removal never descends through one. */
24348 static const char *const links[] = {"alias", "mirror.c", "link.c", "lib"};
24349 for (size_t i = 0; i < sizeof(links) / sizeof(links[0]); i++) {
24350 char path[CBM_SZ_1K];
24351 snprintf(path, sizeof(path), "%s/%s", fx->root, links[i]);
24352 (void)unlink(path);
24353 }
24354 (void)th_rmtree(fx->root);
24355 (void)th_rmtree(fx->outside);
24356}
24357
24358/* File nodes as a stale index holds them: the link targets were ordinary
24359 * directories and files when they were indexed (discovery itself never

Callers 1

test_mcp.cFile · 0.85

Calls 1

th_rmtreeFunction · 0.85

Tested by

no test coverage detected