From e11d5900cd8735fd2ff5ca5308bc028fbe5ed2a5 Mon Sep 17 00:00:00 2001 From: xkchok <143325001+xkchok@users.noreply.github.com> Date: Mon, 31 Aug 2026 09:30:36 +0800 Subject: [PATCH] fix(test): free the return-type table in the go field-chain helper run_go_field_chain_sequential tears down the results, registry and cross arenas but never calls harness_ctx_free_tables, so pass_calls' CBMReturnTypeTable (strdup'd method return types) leaked whenever the helper ran. ASan builds caught it: AddressSanitizer: 32911 byte(s) leaked in 6 allocation(s) from build_return_type_table, failing test-diag, test-lsan-macos and both gcc sanitizer shards. Verify locally: build/c/test-runner parallel -> 73 passed, no leaks. Signed-off-by: xkchok <143325001+xkchok@users.noreply.github.com> --- tests/test_parallel.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/test_parallel.c b/tests/test_parallel.c index 68185dd3b..631446f9c 100644 --- a/tests/test_parallel.c +++ b/tests/test_parallel.c @@ -3282,6 +3282,7 @@ static cbm_gbuf_t *run_go_field_chain_sequential(const char *project, const char cbm_free_result(cache[i]); } free(cache); + harness_ctx_free_tables(&ctx); cbm_registry_free(reg); if (ctx.seq_cross_arena_live) { cbm_arena_destroy(&ctx.seq_cross_arena);