From a584475a8facd93b54ba1419d6cf5a736a500bf6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ermal=20Lu=E7i?= Date: Tue, 22 Dec 2009 13:43:18 +0000 Subject: * Fix alias handling around the repo. * Add new function filter_expand_alias to allow expanding single alias. * Fix reflection rules generation(missing the target variable) * Propperly identify duplicate lines in inetd.conf generated. --- usr/local/www/guiconfig.inc | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) (limited to 'usr/local/www/guiconfig.inc') diff --git a/usr/local/www/guiconfig.inc b/usr/local/www/guiconfig.inc index fa1fdcc..3496d9c 100755 --- a/usr/local/www/guiconfig.inc +++ b/usr/local/www/guiconfig.inc @@ -564,13 +564,9 @@ function address_to_pconfig($adr, &$padr, &$pmask, &$pnot, &$pbeginport, &$pendp list($pbeginport, $pendport) = explode("-", $adr['port']); if (!$pendport) $pendport = $pbeginport; - } else { - if(alias_expand($pbeginport) <> "" || alias_expand($pendport) <> "") { - /* Item is a port alias */ - } else { - $pbeginport = "any"; - $pendport = "any"; - } + else if (!is_alias($pbeginport) && !is_alias($pendport)) { + $pbeginport = "any"; + $pendport = "any"; } } @@ -600,7 +596,7 @@ function pconfig_to_address(&$adr, $padr, $pmask, $pnot=false, $pbeginport=0, $p $adr['port'] = $pbeginport; } - if(alias_expand($pbeginport)) { + if(is_alias($pbeginport)) { $adr['port'] = $pbeginport; } } @@ -993,4 +989,4 @@ function rule_popup($src,$srcport,$dst,$dstport){ } } -?> \ No newline at end of file +?> -- cgit v1.1