Closed JEphron closed 10 years ago
Just noticed that I can manually send a valid closing code with the closeWithCode
method. Is it intended behavior that simply calling close
results in a status code of -1?
I think I ran into this as well. The error code should be 1000, per 7.4.1 of the RFC 6455 protocol specification for WebSocket. http://tools.ietf.org/html/rfc6455#section-7.4.1
On Sun, May 11, 2014 at 4:44 PM, JEphron notifications@github.com wrote:
Just noticed that I can manually send a valid closing code with the closeWithCode method. Is it intended behavior that simply calling closeresults in a status of -1?
— Reply to this email directly or view it on GitHubhttps://github.com/square/SocketRocket/issues/170#issuecomment-42787254 .
Duplicate of issue #127, PR to resolve in #157.
Fixed on master
.
I was having some issues getting SocketRocket to work with my chosen websocket server library, and when I traced the problem it turned out that the server was crashing on an unhandled error code. It looks like SocketRocket sends a -1 when closing a connection. I can't find any mention of this as an accepted status code in the RFC spec. I don't know if this is a real issue, I may have overlooked something in the spec. Just thought I would bring it up here.