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

Unified Diff: net/websockets/websocket_frame.h

Issue 10824081: Add WebSocketError to indicate decoding failure reason (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 years, 5 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 | net/websockets/websocket_frame_parser.h » ('j') | net/websockets/websocket_frame_parser.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/websockets/websocket_frame.h
diff --git a/net/websockets/websocket_frame.h b/net/websockets/websocket_frame.h
index 9f7c7fd6fc26b471fd38cc8db84a7f2f95ea9068..811e8463882ad6f6b84e83959fdf4e2270debb28 100644
--- a/net/websockets/websocket_frame.h
+++ b/net/websockets/websocket_frame.h
@@ -16,6 +16,14 @@ namespace net {
class IOBufferWithSize;
+// Error values for WebSocket framing.
+// This values are compatible to RFC6455 defined status codes.
+enum WebSocketError {
+ WS_OK = 1000,
+ WS_ERR_PROTOCOL_ERROR = 1002,
+ WS_ERR_MESSAGE_TOO_BIG = 1009
mmenke 2012/08/01 14:44:59 It's a bit long, but I think it's worth writing WE
Takashi Toyoshima 2012/08/02 08:11:35 Done.
+};
mmenke 2012/08/01 14:44:59 Wonder if it makes sense to move these to their ow
Takashi Toyoshima 2012/08/02 08:11:35 Done.
+
// Represents a WebSocket frame header.
//
// Members of this class correspond to each element in WebSocket frame header
« no previous file with comments | « no previous file | net/websockets/websocket_frame_parser.h » ('j') | net/websockets/websocket_frame_parser.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698