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

Function rb_add_row

src/cypher/cypher.c:2806–2817  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2804}
2805
2806static void rb_add_row(result_builder_t *rb, const char **values) {
2807 if (rb->row_count >= rb->row_cap) {
2808 rb->row_cap *= PAIR_LEN;
2809 rb->rows = safe_realloc(rb->rows, rb->row_cap * sizeof(const char **));
2810 }
2811 const char **row =
2812 malloc((rb->col_count > 0 ? (size_t)rb->col_count : SKIP_ONE) * sizeof(const char *));
2813 for (int i = 0; i < rb->col_count; i++) {
2814 row[i] = values[i] ? heap_strdup(values[i]) : heap_strdup("");
2815 }
2816 rb->rows[rb->row_count++] = row;
2817}
2818
2819/* ── Main execution ─────────────────────────────────────────────── */
2820

Callers 5

execute_return_starFunction · 0.85
ret_agg_emit_rowFunction · 0.85
execute_return_simpleFunction · 0.85
cbm_cypher_executeFunction · 0.85

Calls 2

safe_reallocFunction · 0.85
heap_strdupFunction · 0.70

Tested by

no test coverage detected