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

Function stream_results_equal

tests/test_cypher.c:5858–5877  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5856}
5857
5858static bool stream_results_equal(const cbm_cypher_result_t *a, const cbm_cypher_result_t *b) {
5859 if (a->col_count != b->col_count || a->row_count != b->row_count ||
5860 a->truncated != b->truncated || !stream_same_str(a->warning, b->warning) ||
5861 !stream_same_str(a->error, b->error)) {
5862 return false;
5863 }
5864 for (int c = 0; c < a->col_count; c++) {
5865 if (strcmp(a->columns[c], b->columns[c]) != 0) {
5866 return false;
5867 }
5868 }
5869 for (int r = 0; r < a->row_count; r++) {
5870 for (int c = 0; c < a->col_count; c++) {
5871 if (strcmp(a->rows[r][c], b->rows[r][c]) != 0) {
5872 return false;
5873 }
5874 }
5875 }
5876 return true;
5877}
5878
5879/* True when every chunk size reproduces the single-pass result, which is
5880 * left in *ref for the caller's own checks (caller frees). */

Callers 1

Calls 1

stream_same_strFunction · 0.85

Tested by

no test coverage detected