Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1106)

Unified Diff: runtime/bin/websocket.dart

Issue 10946007: Never send reserved status codes in a close frame (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | runtime/bin/websocket_impl.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/bin/websocket.dart
diff --git a/runtime/bin/websocket.dart b/runtime/bin/websocket.dart
index ef8876cafd4bdd3928642687a540514ebf409578..b0f492537e34a5f20a48feebe67d2873307a859a 100644
--- a/runtime/bin/websocket.dart
+++ b/runtime/bin/websocket.dart
@@ -70,7 +70,11 @@ interface WebSocketConnection extends Hashable {
* Sets the callback to be called when the web socket connection is
* closed. [status] indicate the reason for closing. For network
* errors the value of [status] will be
- * WebSocketStatus.ABNORMAL_CLOSURE].
+ * WebSocketStatus.ABNORMAL_CLOSURE]. In this callbach it is
+ * possible to call [close] if [close] has not already been called.
+ * If [close] has still not been called after the close callback
+ * returns the received close status will automatically be echoed
+ * back to the other end to finish the close handshake.
*/
void set onClosed(void callback(int status, String reason));
« no previous file with comments | « no previous file | runtime/bin/websocket_impl.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698