From 8a2f41aa8bf75791402f4a9ddaa4be71e5569bbb Mon Sep 17 00:00:00 2001
From: Arne Goedeke <el@laramies.com>
Date: Fri, 15 Aug 2014 12:05:54 +0200
Subject: [PATCH] Protocols.WebSocket: make the stream and parser available

---
 lib/modules/Protocols.pmod/WebSocket.pmod | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/lib/modules/Protocols.pmod/WebSocket.pmod b/lib/modules/Protocols.pmod/WebSocket.pmod
index 0824446d0d..7fa114dd97 100644
--- a/lib/modules/Protocols.pmod/WebSocket.pmod
+++ b/lib/modules/Protocols.pmod/WebSocket.pmod
@@ -73,7 +73,8 @@ string describe_opcode(FRAME op) {
 
 //! Parses WebSocket frames.
 class Parser {
-    protected string buf = "";
+    //! Unparsed data.
+    string buf = "";
 
     //! Add more data to the internal parsing buffer.
     void feed(string data) {
@@ -242,9 +243,12 @@ class Frame {
 
 //!
 class Connection {
-    protected object parser;
+    //! An instance of @[Parser] used to parse incoming data.
+    object parser;
+
+    //! The actual client connection.
+    Stdio.File stream;
 
-    protected Stdio.File stream;
     protected array(string) stream_buf = ({ });
     protected int(0..1) will_write = 1;
     protected mixed id;
-- 
GitLab