Skip to content

Commit

Permalink
[minor] Make the uws transformer work on Windows
Browse files Browse the repository at this point in the history
  • Loading branch information
lpinca committed Jul 11, 2016
1 parent c1d3034 commit d3b57d5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion transformers/uws/server.js
Expand Up @@ -48,7 +48,10 @@ module.exports = function server() {

if (secKey && secKey.length === 24) {
soc.setNoDelay(options.transport.noDelay);
ticket = service.transfer(soc._handle.fd, soc.ssl ? soc.ssl._external : null);
ticket = service.transfer(
soc._handle.fd === -1 ? soc._handle : soc._handle.fd,
soc.ssl ? soc.ssl._external : null
);

soc.on('close', function destroy() {
service.onConnection(function create(socket) {
Expand Down

0 comments on commit d3b57d5

Please sign in to comment.