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

Function read_batch_name

tests/test_store_pragmas.c:351–359  ·  view source on GitHub ↗

A read tool's statements share one read batch instead of taking the file * lock once per statement. The batch reads one snapshot until it renews * (every 100 ms, forced here through the seam), then sees later commits. */

Source from the content-addressed store, hash-verified

349 * lock once per statement. The batch reads one snapshot until it renews
350 * (every 100 ms, forced here through the seam), then sees later commits. */
351static char *read_batch_name(cbm_store_t *s) {
352 cbm_node_t found = {0};
353 if (cbm_store_find_node_by_qn(s, "p", "p.a", &found) != CBM_STORE_OK) {
354 return NULL;
355 }
356 char *name = found.name ? strdup(found.name) : NULL;
357 cbm_node_free_fields(&found);
358 return name;
359}
360
361static bool read_batch_rename(cbm_store_t *writer, const char *name) {
362 cbm_node_t node = {

Callers 1

Calls 2

cbm_node_free_fieldsFunction · 0.85

Tested by

no test coverage detected