You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
varfs=require('fs');vartls=require('tls');varnet=require('net');varhttp=require('http');if('server'==process.argv[2]){varhttpServer=http.createServer(function(request,response){response.end('Waiting for a client');});httpServer.on('upgrade',function(request,socket,head){socket.write('HTTP/1.1 101 Web Socket Protocol Handshake\r\n'+'Upgrade: websocket\r\n'+'Connection: Upgrade\r\n'+'\r\n');newtls.TLSSocket(socket);console.log('>>> OK <<<');});varserver=net.createServer();server.on('connection',function(connection){httpServer.emit('connection',connection);});server.listen('5000');}else{varrequest=http.request({host: 'localhost',port: '5000',headers: {'Connection': 'Upgrade','Upgrade': 'websocket'}});request.end();}
Reset the underlying socket of an HTTP stream to be marked as
unconsume after the HTTP parser no longer owns it.
Fixes: #14407
PR-URL: #14410
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reset the underlying socket of an HTTP stream to be marked as
unconsume after the HTTP parser no longer owns it.
Fixes: #14407
PR-URL: #14410
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Script:
Core Dump:
The text was updated successfully, but these errors were encountered: