mirror of
https://github.com/apple/swift-nio-extras
synced 2026-11-26 04:57:49 +00:00
Motivation: `NIOHTTPDecompression` erroneously accumulates decompressed data sizes across multiple requests in a single channel, leading to unwarranted `DecompressionError.limit` errors. This affects applications using persistent connections, as the decompression limits are improperly enforced. This change aims to address and rectify this issue. Modifications: - Add initialization of `inflated` within `Decompressor.initializeDecoder`. - Introduced new tests to validate decompression functionality across multiple requests on the same channel Result: This fix ensures each request's decompression size is independently considered, eliminating incorrect limit errors, and enhancing reliability for applications using HTTP compression with persistent connections.