summaryrefslogtreecommitdiffstats
path: root/etc/inc
diff options
context:
space:
mode:
authorColin Smith <colin@pfsense.org>2005-08-06 23:17:24 +0000
committerColin Smith <colin@pfsense.org>2005-08-06 23:17:24 +0000
commitd96e7a05ad1a81b665729d6eb0441642d3d3be87 (patch)
tree70318cf7f39b905b6548cc64f755cf76de6e484f /etc/inc
parent506672630f540e21dca5eb054acba432960a3030 (diff)
downloadpfsense-d96e7a05ad1a81b665729d6eb0441642d3d3be87.zip
pfsense-d96e7a05ad1a81b665729d6eb0441642d3d3be87.tar.gz
is_process_running():
* grep -v grep * 2 -> 0
Diffstat (limited to 'etc/inc')
-rw-r--r--etc/inc/service-utils.inc4
1 files changed, 2 insertions, 2 deletions
diff --git a/etc/inc/service-utils.inc b/etc/inc/service-utils.inc
index 0787b20..2c9b117 100644
--- a/etc/inc/service-utils.inc
+++ b/etc/inc/service-utils.inc
@@ -123,8 +123,8 @@ function restart_service($name) {
}
function is_process_running($process) {
- $status = `/bin/ps ax | /usr/bin/grep {$process} | wc -l`;
- if($status > 2) return 1;
+ $status = `/bin/ps ax | /usr/bin/grep {$process} | grep -v grep | wc -l`;
+ if($status > 0) return 1;
return 0;
}
OpenPOWER on IntegriCloud