summaryrefslogtreecommitdiffstats
path: root/etc/rc.newwanip
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2006-07-21 21:08:31 +0000
committerScott Ullrich <sullrich@pfsense.org>2006-07-21 21:08:31 +0000
commitceaf11adfae45fb187e7d744ac6e373c2cb70d28 (patch)
tree8e2b62a4a3dba4c89f50ffef4828b5af54903cd2 /etc/rc.newwanip
parent7ca5e0574e2860ba323f374087f0dfb9093ab2d1 (diff)
downloadpfsense-ceaf11adfae45fb187e7d744ac6e373c2cb70d28.zip
pfsense-ceaf11adfae45fb187e7d744ac6e373c2cb70d28.tar.gz
Only attempt kill if $helpers is defined
Diffstat (limited to 'etc/rc.newwanip')
-rwxr-xr-xetc/rc.newwanip3
1 files changed, 2 insertions, 1 deletions
diff --git a/etc/rc.newwanip b/etc/rc.newwanip
index bf3e05f..d22cc22 100755
--- a/etc/rc.newwanip
+++ b/etc/rc.newwanip
@@ -51,7 +51,8 @@
if(file_exists("/tmp/rc.newwanip_oldip")) {
$old_ip = file_get_contents("/tmp/rc.newwanip_oldip");
$helpers = exec("/bin/ps awux | grep \"{$old_ip}\" | grep -v \"grep\" | awk '{ print $6 }'");
- mwexec("kill " . trim($helpers));
+ if($helpers)
+ mwexec("kill " . trim($helpers));
unlink("/tmp/rc.newwanip_oldip");
}
OpenPOWER on IntegriCloud