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

Function version_test_cleanup

tests/test_daemon_version.c:112–133  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

110}
111
112static void version_test_cleanup(const char *dir, const char *path, const char *rotated,
113 const char *victim) {
114 char lock_path[VERSION_TEST_PATH_CAP];
115 if (path) {
116 int written = snprintf(lock_path, sizeof(lock_path), "%s.lock", path);
117 if (written > 0 && written < (int)sizeof(lock_path)) {
118 (void)cbm_unlink(lock_path);
119 }
120 }
121 if (path) {
122 (void)cbm_unlink(path);
123 }
124 if (rotated) {
125 (void)cbm_unlink(rotated);
126 }
127 if (victim) {
128 (void)cbm_unlink(victim);
129 }
130 if (dir) {
131 (void)cbm_rmdir(dir);
132 }
133}
134
135#ifndef _WIN32
136typedef struct {

Callers 1

Calls 2

cbm_unlinkFunction · 0.85
cbm_rmdirFunction · 0.85

Tested by

no test coverage detected