diff --git a/lib/master.js b/lib/master.js index e4a4627..da58d8c 100644 --- a/lib/master.js +++ b/lib/master.js @@ -260,6 +260,7 @@ Master.prototype.start = function(fn){ if (this.isWorker) { // connect the worker var worker = new Worker(this); + this.worker = worker; this.sock = net.createConnection(this.socketPath); this.sock.on('connect', function(){ worker.start();