Only add outgoing-interface if IP. Ticket #4852

This commit is contained in:
Chris Buechler 2015-07-17 13:00:27 -05:00
parent e4b7410b9b
commit 4df4c7d6b5

View File

@ -166,10 +166,10 @@ EOF;
$outgoing_interfaces = explode(",", $config['unbound']['outgoing_interface']);
foreach($outgoing_interfaces as $outif) {
$outip = get_interface_ip($outif);
if (!is_null($outip))
if (is_ipaddr($outip))
$outgoingints .= "outgoing-interface: $outip\n";
$outip = get_interface_ipv6($outif);
if (!is_null($outip))
if (is_ipaddrv6($outip))
$outgoingints .= "outgoing-interface: $outip\n";
}
}