(err error)
| 310 | } |
| 311 | |
| 312 | func findHTTP2StreamError(err error) (http2.StreamError, bool) { |
| 313 | var streamErr http2.StreamError |
| 314 | if errors.As(err, &streamErr) { |
| 315 | return streamErr, true |
| 316 | } |
| 317 | var streamErrPtr *http2.StreamError |
| 318 | if errors.As(err, &streamErrPtr) && streamErrPtr != nil { |
| 319 | return *streamErrPtr, true |
| 320 | } |
| 321 | return http2.StreamError{}, false |
| 322 | } |
| 323 | |
| 324 | func isPeerHTTP2StreamError(streamErr http2.StreamError) bool { |
| 325 | return streamErr.Cause != nil && streamErr.Cause.Error() == http2PeerResetCause |
no test coverage detected