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

Function walk_push_subdir

src/discover/discover.c:675–685  ·  view source on GitHub ↗

Push a subdirectory onto the walk stack, inheriting local gitignore context. */

Source from the content-addressed store, hash-verified

673
674/* Push a subdirectory onto the walk stack, inheriting local gitignore context. */
675static void walk_push_subdir(walk_frame_t *stack, int *top, const char *abs_path,
676 const char *rel_path, const walk_frame_t *parent) {
677 if (*top >= WALK_STACK_CAP) {
678 return;
679 }
680 snprintf(stack[*top].dir, CBM_SZ_4K, "%s", abs_path);
681 snprintf(stack[*top].prefix, CBM_SZ_4K, "%s", rel_path);
682 stack[*top].local_gi = parent->local_gi;
683 snprintf(stack[*top].local_gi_prefix, CBM_SZ_4K, "%s", parent->local_gi_prefix);
684 (*top)++;
685}
686
687static void walk_dir_process_entry(cbm_dirent_t *entry, const walk_frame_t *frame,
688 const cbm_discover_opts_t *opts,

Callers 1

walk_dir_process_entryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected