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

Function lrp_cleanup

tests/test_lsp_resolution_probe.c:165–175  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

163}
164
165static void lrp_cleanup(LRP_Proj *lp, cbm_store_t *store) {
166 if (store) cbm_store_close(store);
167 if (lp->srv) { cbm_mcp_server_free(lp->srv); lp->srv = NULL; }
168 free(lp->project); lp->project = NULL;
169 th_rmtree(lp->tmpdir);
170 unlink(lp->dbpath);
171 char wal[600], shm[600];
172 snprintf(wal, sizeof(wal), "%s-wal", lp->dbpath);
173 snprintf(shm, sizeof(shm), "%s-shm", lp->dbpath);
174 unlink(wal); unlink(shm);
175}
176
177/* Returns USAGE edge count (-1 on DB failure). */
178static int lrp_usage(LRP_Proj *lp, const LRP_File *files, int nfiles) {

Callers 3

lrp_usageFunction · 0.85
lrp_assert_callsFunction · 0.85

Calls 3

cbm_store_closeFunction · 0.85
cbm_mcp_server_freeFunction · 0.85
th_rmtreeFunction · 0.85

Tested by

no test coverage detected