playframework/playframework — pull request #2458 by andrewconner (2014-03-07 03:46:26+00:00)
Title: Send close control frame on client-initiated disconnects

Fixes #2456. On a client initiated disconnect (when the server receives a close control frame), reply with a close control frame, as per the [WebSocket Protocol RFC](http://tools.ietf.org/html/rfc6455#section-5.5.1).

Original bug report and code written by @2is10, who sits across from me and was ready to move on from this issue :)

On proper client-initiated disconnect:
![](http://i.imgur.com/nd8SBJR.png)

A back-port would be appreciated to 2.2.x.