diff --git a/index.js b/index.js index 6eb3de7d..a02e4544 100644 --- a/index.js +++ b/index.js @@ -137,7 +137,13 @@ function startServer(server) { } function getSocketPath(socketPathSuffix) { + if (/^win/.test(process.platform)) { + const path = require('path') + return path.join('\\\\?\\pipe', process.cwd(), `server${socketPathSuffix}`) + } + else { return `/tmp/server${socketPathSuffix}.sock` + } } function createServer (requestListener, serverListenCallback, binaryTypes) {