summaryrefslogtreecommitdiffstats
path: root/src/etc/inc/interfaces.inc
diff options
context:
space:
mode:
authorLuiz Otavio O Souza <luiz@netgate.com>2016-02-16 10:51:42 -0600
committerLuiz Otavio O Souza <luiz@netgate.com>2016-02-16 10:51:42 -0600
commit985118b8b15bef26c4eb1a11f25373b3a24d0a97 (patch)
tree7964e75ea2dceac84f6a8cce14e9268be84d28dc /src/etc/inc/interfaces.inc
parente0e28fdf6af0e1e87c930bae0ad0a8d1eb62465e (diff)
downloadpfsense-985118b8b15bef26c4eb1a11f25373b3a24d0a97.zip
pfsense-985118b8b15bef26c4eb1a11f25373b3a24d0a97.tar.gz
Simplify the code with the use the newly introduced function to list CARP addresses.
Diffstat (limited to 'src/etc/inc/interfaces.inc')
-rw-r--r--src/etc/inc/interfaces.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/etc/inc/interfaces.inc b/src/etc/inc/interfaces.inc
index 800ff42..53fa9ba 100644
--- a/src/etc/inc/interfaces.inc
+++ b/src/etc/inc/interfaces.inc
@@ -2160,7 +2160,8 @@ function interfaces_sync_setup() {
mwexec("/sbin/ifconfig pfsync0 -syncdev -syncpeer down", false);
}
- if ($config['virtualip']['vip']) {
+ $carplist = get_configured_vip_list('all', VIP_CARP);
+ if (isset($carplist) && is_array($carplist) && count($carplist) > 0) {
set_single_sysctl("net.inet.carp.allow", "1");
} else {
set_single_sysctl("net.inet.carp.allow", "0");
OpenPOWER on IntegriCloud