Fixed using the wrong decompression function for gzip

This commit is contained in:
Caleb J. Gardner
2026-03-17 22:17:11 -05:00
parent b5742bc282
commit 8002e745e0
+1 -1
View File
@@ -43,7 +43,7 @@ fn zigGzip(alloc: std.mem.Allocator, in: []u8, out: []u8) anyerror!usize {
fn cGzip(alloc: std.mem.Allocator, in: []u8, out: []u8) anyerror!usize { fn cGzip(alloc: std.mem.Allocator, in: []u8, out: []u8) anyerror!usize {
_ = alloc; _ = alloc;
var out_len: usize = out.len; var out_len: usize = out.len;
const res = c.zng_uncompress2(out.ptr, &out_len, in.ptr, in.len); const res = c.zng_uncompress(out.ptr, &out_len, in.ptr, in.len);
return switch (res) { return switch (res) {
c.Z_OK => out_len, c.Z_OK => out_len,
c.Z_MEM_ERROR => error.NotEnoughMemory, c.Z_MEM_ERROR => error.NotEnoughMemory,