authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2026-05-25 20:17:41-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2026-05-25 20:17:41-07:00
log5b022623cf7059b76d3bbc91c71a93ab96adbdeb
tree5bc8a5d047e311a9c3b03ee5bcba395c13fb9478
parentf3dd10d40fb9b6b94ccf7729c728c80ebd608ba7

Maker.Step.Compile: fix memory leak in checkCompileErrors


1 files changed, 2 insertions(+), 1 deletions(-)

lib/compiler/Maker/Step/Compile.zig+2-1
......@@ -991,8 +991,9 @@ fn checkCompileErrors(arena: Allocator, maker: *Maker, step_index: Configuration
991991 const conf_comp = conf_step.extended.get(conf.extra).compile;
992992
993993 // Clear this field so that it does not get printed by the build runner.
994 const actual_eb = step.result_error_bundle;
994 var actual_eb = step.result_error_bundle;
995995 step.result_error_bundle = .empty;
996 defer actual_eb.deinit(maker.gpa);
996997
997998 const actual_errors = ae: {
998999 var aw: std.Io.Writer.Allocating = .init(arena);