Files
swift-nio-http2/Sources
George Barnett 2624ccc6d6 Use case-insensitive comparision rather than lowercasing (#308)
Motivation:

When getting the canonical form of headers we check whether the header
name is 'set-cookie' to avoid splitting values which are not safe to
split.

This check is done against a `lowercased()` version of the header name.
However, we don't need to produce a new `String` here as we already have
a case insensitive string comparision function.

Modifications:

- Add a test to verify that getting the canonical form of "set-cookie"
  does not split any header values
- Switch to `isEqualCaseInsensitiveASCIIBytes`

Result:

More tests, cheaper comparision.
2021-09-29 13:43:18 +01:00
..