also pass hello packet

This commit is contained in:
AJ ONeal 2016-10-05 23:10:16 -06:00
parent 495dc57fb0
commit c57b8f6a6d
2 changed files with 4 additions and 1 deletions

View File

@ -113,9 +113,11 @@ program.net = {
myDuplex.localFamily = socket.localFamily;
myDuplex.localAddress = socket.localAddress;
myDuplex.localPort = socket.localPort;
httpsServer.emit('connection', myDuplex);
*/
// info = { servername, port, host, remoteAddress: { family, address, port } }
// data is the hello packet / first chunk
// info = { data, servername, port, host, remoteAddress: { family, address, port } }
var net = require('net');
// socket = { write, push, end, events: [ 'readable', 'data', 'error', 'end' ] };
var socket = net.createConnection({ port: info.port, host: info.host }, cb);

View File

@ -87,6 +87,7 @@ function run(copts) {
servername: servername
, port: port
, host: '127.0.0.1'
, data: opts.data
, remoteAddress: {
family: opts.family
, address: opts.address