There was an error while loading. Please reload this page.
2 parents f49dda4 + 6cb7c32 commit 862762fCopy full SHA for 862762f
1 file changed
Sources/NIOHTTP3/HTTP3StreamHandler.swift
@@ -332,20 +332,12 @@ package final class HTTP3StreamHandler: ChannelDuplexHandler {
332
}
333
case let error as QUICConnectionError:
334
self.logger.trace("Caught CONNECTION_CLOSE")
335
- let h3Code: HTTP3ErrorCode?
336
- if error.isApplication {
337
- // RFC 9114 § 8: "Receipt of an unknown error code MUST be treated as equivalent to
338
- // H3_NO_ERROR."
339
- h3Code = HTTP3ErrorCode(rawValue: error.code)
340
- } else {
341
- h3Code = nil
342
- }
343
context.fireErrorCaught(
344
HTTP3Error(
345
code: .remoteConnectionError,
346
message: error.reason,
347
cause: error,
348
- errorCode: h3Code,
+ errorCode: error.isApplication ? HTTP3ErrorCode(rawValue: error.code) : nil,
349
location: .here()
350
)
351
0 commit comments