Add clarifying comment to use of kill in isProcessRunning

This commit is contained in:
Ryan Huffman 2017-06-02 08:58:35 -07:00
parent 86da91ac8d
commit de2f8bd944

View file

@ -823,6 +823,9 @@ const notificationIcon = path.join(__dirname, '../resources/console-notification
function isProcessRunning(pid) {
try {
// Sending a signal of 0 is effectively a NOOP.
// If sending the signal is successful, kill will return true.
// If the process is not running, an exception will be thrown.
return process.kill(pid, 0);
} catch (e) {
}