diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2025-07-25 22:10:29 -0700 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2025-07-31 22:10:11 -0700 |
| commit | 83513ade3591de673e9ac4824fe974cd8f90c847 (patch) | |
| tree | 5a581e31b4b004061673ac1e44e669e1808be3bd /lib/std/http | |
| parent | a2d21d63270ebb5eec0d437f7726c261455da66b (diff) | |
| download | zig-83513ade3591de673e9ac4824fe974cd8f90c847.tar.gz zig-83513ade3591de673e9ac4824fe974cd8f90c847.zip | |
std.compress: rework flate to new I/O API
Diffstat (limited to 'lib/std/http')
| -rw-r--r-- | lib/std/http/Client.zig | 9 | ||||
| -rw-r--r-- | lib/std/http/Server.zig | 4 |
2 files changed, 4 insertions, 9 deletions
diff --git a/lib/std/http/Client.zig b/lib/std/http/Client.zig index 838411bebc..83c1c8b50b 100644 --- a/lib/std/http/Client.zig +++ b/lib/std/http/Client.zig @@ -405,13 +405,8 @@ pub const RequestTransfer = union(enum) { /// The decompressor for response messages. pub const Compression = union(enum) { - pub const DeflateDecompressor = std.compress.zlib.Decompressor(Request.TransferReader); - pub const GzipDecompressor = std.compress.gzip.Decompressor(Request.TransferReader); - // https://github.com/ziglang/zig/issues/18937 - //pub const ZstdDecompressor = std.compress.zstd.DecompressStream(Request.TransferReader, .{}); - - deflate: DeflateDecompressor, - gzip: GzipDecompressor, + deflate: std.compress.flate.Decompress, + gzip: std.compress.flate.Decompress, // https://github.com/ziglang/zig/issues/18937 //zstd: ZstdDecompressor, none: void, diff --git a/lib/std/http/Server.zig b/lib/std/http/Server.zig index 886aed72dc..7ec5d5c11f 100644 --- a/lib/std/http/Server.zig +++ b/lib/std/http/Server.zig @@ -130,8 +130,8 @@ pub const Request = struct { pub const DeflateDecompressor = std.compress.zlib.Decompressor(std.io.AnyReader); pub const GzipDecompressor = std.compress.gzip.Decompressor(std.io.AnyReader); - deflate: DeflateDecompressor, - gzip: GzipDecompressor, + deflate: std.compress.flate.Decompress, + gzip: std.compress.flate.Decompress, zstd: std.compress.zstd.Decompress, none: void, }; |
