Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15289273
D18411.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
943 B
Referenced Files
None
Subscribers
None
D18411.diff
View Options
diff --git a/support/aphlict/server/lib/AphlictClientServer.js b/support/aphlict/server/lib/AphlictClientServer.js
--- a/support/aphlict/server/lib/AphlictClientServer.js
+++ b/support/aphlict/server/lib/AphlictClientServer.js
@@ -92,8 +92,14 @@
var server = this._server.listen.apply(this._server, arguments);
var wss = new WebSocket.Server({server: server});
- wss.on('connection', function(ws) {
- var path = url.parse(ws.upgradeReq.url).pathname;
+ // This function checks for upgradeReq which is only available in
+ // ws2 by default, not ws3. See T12755 for more information.
+ wss.on('connection', function(ws, request) {
+ if ('upgradeReq' in ws) {
+ request = ws.upgradeReq;
+ }
+
+ var path = url.parse(request.url).pathname;
var instance = self._parseInstanceFromPath(path);
var listener = self.getListenerList(instance).addListener(ws);
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Mar 5, 9:38 PM (11 h, 17 m ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
7227464
Default Alt Text
D18411.diff (943 B)
Attached To
Mode
D18411: Update AphlictClientServer to support ws2 or ws3
Attached
Detach File
Event Timeline
Log In to Comment