We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 40c87b9 commit df776d4Copy full SHA for df776d4
proto.go
@@ -394,8 +394,9 @@ func validateFrame(frame *Frame) error {
394
if payloadLen == 0 {
395
return nil
396
}
397
- // if a close frame has a payload, the first two bytes must encode a
+ // if a close frame has a payload, the first two bytes MUST encode a
398
// closing status code.
399
+ // https://datatracker.ietf.org/doc/html/rfc6455#section-5.5.1
400
if payloadLen == 1 {
401
return ErrClosePayloadInvalid
402
0 commit comments