mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
Prevent a invalid argument on a empty array
This commit is contained in:
parent
c08a5659d8
commit
4b2bf4fc01
@ -265,6 +265,8 @@ function system_hosts_generate() {
|
||||
foreach ($dhcpifconf['staticmap'] as $host)
|
||||
if ($host['ipaddr'] && $host['hostname'])
|
||||
$dhosts .= "{$host['ipaddr']} {$host['hostname']}.{$syscfg['domain']} {$host['hostname']}\n";
|
||||
}
|
||||
if (isset($dnsmasqcfg['regdhcpstatic']) && is_array($config['dhcpdv6'])) {
|
||||
foreach ($config['dhcpdv6'] as $dhcpif => $dhcpifconf)
|
||||
if(is_array($dhcpifconf['staticmap']) && isset($dhcpifconf['enable']))
|
||||
foreach ($dhcpifconf['staticmap'] as $host)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user