Commit 1a68b131 authored by Brad Fitzpatrick's avatar Brad Fitzpatrick

http2: fix up comment on unexported connError type

It apparently used to be called connErrorReason but when it was
renamed the comment wasn't updated. Also, the comment was split via a
blank line, detaching it from its decl node.

Change-Id: I4ae510fc0e48fd61f40489428f9da4c6cab3ef2f
Reviewed-on: https://go-review.googlesource.com/45273Reviewed-by: 's avatarHiroshi Ioka <hirochachacha@gmail.com>
Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
parent e78b1e49
...@@ -87,13 +87,16 @@ type goAwayFlowError struct{} ...@@ -87,13 +87,16 @@ type goAwayFlowError struct{}
func (goAwayFlowError) Error() string { return "connection exceeded flow control window size" } func (goAwayFlowError) Error() string { return "connection exceeded flow control window size" }
// connErrorReason wraps a ConnectionError with an informative error about why it occurs. // connError represents an HTTP/2 ConnectionError error code, along
// with a string (for debugging) explaining why.
//
// Errors of this type are only returned by the frame parser functions // Errors of this type are only returned by the frame parser functions
// and converted into ConnectionError(ErrCodeProtocol). // and converted into ConnectionError(Code), after stashing away
// the Reason into the Framer's errDetail field, accessible via
// the (*Framer).ErrorDetail method.
type connError struct { type connError struct {
Code ErrCode Code ErrCode // the ConnectionError error code
Reason string Reason string // additional reason
} }
func (e connError) Error() string { func (e connError) Error() string {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment