sending 'bind' message to child proc instead of SIGCONT signal, which is not understood by Windows installs

v1.18.x
Julian Lam 11 years ago
parent 14fcd36134
commit 9ea081deb3

@ -143,7 +143,11 @@ function start() {
plugins.ready(function() {
webserver.init(function() {
// If this callback is called, this means that loader.js is used
process.on('SIGCONT', webserver.listen);
process.on('message', function(msg) {
if (msg === 'bind') {
webserver.listen();
}
});
process.send({
action: 'ready'
});

@ -29,7 +29,7 @@ var nconf = require('nconf'),
if (message && typeof message === 'object' && message.action) {
switch (message.action) {
case 'ready':
if (!callback) return nbb.kill('SIGCONT');
if (!callback) return nbb.send('bind');
callback();
break;
case 'restart':
@ -63,7 +63,7 @@ var nconf = require('nconf'),
nbb_restart = function() {
nbb_start(function() {
nbbOld.removeAllListeners('exit').on('exit', function() {
nbb.kill('SIGCONT');
nbb.send('bind');
});
nbbOld.kill();
});

Loading…
Cancel
Save