summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2013-09-27 13:11:17 -0400
committerjim-p <jimp@pfsense.org>2013-09-27 13:14:18 -0400
commitf3a4601c85c4de78caa4f12fefd64067fd83dbe8 (patch)
treec142c56b49e64d9430d469b3c5aab77c8c1a09bf /etc
parentf58bfb932acf9924546d3b9a2c77899741adeb9a (diff)
downloadpfsense-f3a4601c85c4de78caa4f12fefd64067fd83dbe8.zip
pfsense-f3a4601c85c4de78caa4f12fefd64067fd83dbe8.tar.gz
If rc.newwanip is run on an interface that should not have an IP address, do not take any action.
Diffstat (limited to 'etc')
-rwxr-xr-xetc/rc.newwanip4
1 files changed, 4 insertions, 0 deletions
diff --git a/etc/rc.newwanip b/etc/rc.newwanip
index f9c23af..beeb0b8 100755
--- a/etc/rc.newwanip
+++ b/etc/rc.newwanip
@@ -76,6 +76,10 @@ else {
$curwanip = find_interface_ip($interface_real, true);
if($curwanip == "")
$curwanip = get_interface_ip($interface);
+ if (($curwanip == "") && !(isset($config['interfaces'][$interface]['ipaddr']))) {
+ log_error("Interface does not have an IP address, nothing to do.");
+ return;
+ }
}
log_error("rc.newwanip: on (IP address: {$curwanip}) (interface: {$interface}) (real interface: {$interface_real}).");
OpenPOWER on IntegriCloud