uperl / AnyEvent-WebSocket-Client

WebSocket client for AnyEvent
9 stars 10 forks source link

Use 1000 as the default close code instead of 1005 #62

Closed plicease closed 1 year ago

plicease commented 1 year ago

https://www.rfc-editor.org/rfc/rfc6455.html#section-7.4.1

1000

  1000 indicates a normal closure, meaning that the purpose for
  which the connection was established has been fulfilled.

...

1005

  1005 is a reserved value and MUST NOT be set as a status code in a
  Close control frame by an endpoint.  It is designated for use in
  applications expecting a status code to indicate that no status
  code was actually present.