This commit is contained in:
Julian Lam
2014-11-17 14:47:36 -05:00
parent 14ba1ff8c0
commit 0d6be40238
2 changed files with 15 additions and 3 deletions

7
nodebb
View File

@@ -12,10 +12,11 @@ fi
function pidExists() {
if [ -e "pidfile" ];
then
kill -s 0 $(cat pidfile);
if [ !$? ];
if ps -p $(cat pidfile) > /dev/null
then return 1;
else return 0;
else
rm ./pidfile;
return 0;
fi
else
return 0;