Skip to content
Snippets Groups Projects
Commit 80ac8549 authored by Arne Goedeke's avatar Arne Goedeke
Browse files

Protocols.Websocket.Request: call ::parse_request

Call ::parse_request() for WebSocket requests, too. parse_request parses
not_query and other information, which is useful to have in WebSocket
requests, aswell.
parent 7ad9335d
Branches
Tags
No related merge requests found
......@@ -442,10 +442,8 @@ class Request(function(array(string), Request:void) cb) {
inherit Protocols.HTTP.Server.Request;
protected void parse_request() {
if (!cb || !has_index(request_headers, "sec-websocket-key")) {
::parse_request();
return;
} else {
if (cb && has_index(request_headers, "sec-websocket-key")) {
string proto = request_headers["sec-websocket-protocol"];
array(string) protocols = proto ? proto / ", " : ({});
#ifdef WEBSOCKET_DEBUG
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment