-
Notifications
You must be signed in to change notification settings - Fork 19
Script being kept alive #4
Copy link
Copy link
Open
Description
The script doesn't exit automatically like it should when waitpid has been used. Commenting out the line that waits causes the script to run for 1 second then quit, as expected. With waitpid, however, the script just keeps running.
var waitpid = require('waitpid');
var childProcess = require('child_process');
var child = childProcess.spawn('sh', ['-c', 'sleep 1']);
console.log('waiting..');
waitpid(child.pid);
console.log('done waiting');Tested with Node.js v0.10.4 on OS X and v0.10.7 on Debian 6.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels