diff --git a/src/etc/inc/system.inc b/src/etc/inc/system.inc index c25fbabe6..cb31d6d04 100644 --- a/src/etc/inc/system.inc +++ b/src/etc/inc/system.inc @@ -757,17 +757,9 @@ EOD; file_put_contents('/var/etc/syslog.conf', $syslogconf); if (!empty($syslogcfg['sourceip'])) { - if ($syslogcfg['ipproto'] == "ipv6") { - $ifaddr = is_ipaddr($syslogcfg['sourceip']) ? $syslogcfg['sourceip'] : get_interface_ipv6($syslogcfg['sourceip']); - if (!is_ipaddr($ifaddr)) { - $ifaddr = get_interface_ip($syslogcfg['sourceip']); - } - } else { - $ifaddr = is_ipaddr($syslogcfg['sourceip']) ? $syslogcfg['sourceip'] : get_interface_ip($syslogcfg['sourceip']); - if (!is_ipaddr($ifaddr)) { - $ifaddr = get_interface_ipv6($syslogcfg['sourceip']); - } - } + $ifaddr = $syslogcfg['ipproto'] == 'ipv6' ? + get_interface_ipv6($syslogcfg['sourceip']) : + get_interface_ip($syslogcfg['sourceip']); if (is_ipaddr($ifaddr)) { $syslogd_extra .= exec_safe('-b %s ', $ifaddr); } diff --git a/src/www/diag_logs_settings.php b/src/www/diag_logs_settings.php index db0b57f3c..dc1bbac27 100644 --- a/src/www/diag_logs_settings.php +++ b/src/www/diag_logs_settings.php @@ -1,33 +1,33 @@ - Copyright (C) 2004-2009 Scott Ullrich - Copyright (C) 2003-2004 Manuel Kasper - All rights reserved. - - Redistribution and use in source and binary forms, with or without - modification, are permitted provided that the following conditions are met: - - 1. Redistributions of source code must retain the above copyright notice, - this list of conditions and the following disclaimer. - - 2. Redistributions in binary form must reproduce the above copyright - notice, this list of conditions and the following disclaimer in the - documentation and/or other materials provided with the distribution. - - THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, - INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY - AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, - OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF - SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS - INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN - CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) - ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - POSSIBILITY OF SUCH DAMAGE. -*/ + * Copyright (C) 2014-2015 Deciso B.V. + * Copyright (C) 2007 Seth Mos + * Copyright (C) 2004-2009 Scott Ullrich + * Copyright (C) 2003-2004 Manuel Kasper + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, + * this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, + * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, + * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ require_once("guiconfig.inc"); require_once("interfaces.inc"); @@ -342,7 +342,7 @@ $(document).ready(function() { - + @@ -421,7 +421,7 @@ $(document).ready(function() { - + onclick="enable_change(false)" /> @@ -447,15 +447,13 @@ $(document).ready(function() { - + + $ifdescr): ?> + - + - +