d78f37ec8f
Co-authored-by: Milan Burda <miburda@microsoft.com>
16 lines
390 B
JavaScript
16 lines
390 B
JavaScript
const path = require('node:path');
|
|
|
|
process.on('uncaughtException', function (error) {
|
|
process.send(error.stack);
|
|
});
|
|
|
|
const child = require('node:child_process').fork(path.join(__dirname, '/ping.js'));
|
|
process.on('message', function (msg) {
|
|
child.send(msg);
|
|
});
|
|
child.on('message', function (msg) {
|
|
process.send(msg);
|
|
});
|
|
child.on('exit', function (code) {
|
|
process.exit(code);
|
|
});
|