From: Stefan Schantl Date: Fri, 12 Jun 2020 16:09:46 +0000 (+0200) Subject: logs.cgi/firewalllogcountry.dat: Use location-functions.pl X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=1b024e999ec0eb256cac9f59bf7e76c2dba2b80e;p=people%2Fmfischer%2Fipfire-2.x.git logs.cgi/firewalllogcountry.dat: Use location-functions.pl Signed-off-by: Stefan Schantl --- diff --git a/html/cgi-bin/logs.cgi/firewalllogcountry.dat b/html/cgi-bin/logs.cgi/firewalllogcountry.dat index c241b03205..701abab2c8 100644 --- a/html/cgi-bin/logs.cgi/firewalllogcountry.dat +++ b/html/cgi-bin/logs.cgi/firewalllogcountry.dat @@ -18,12 +18,12 @@ use Getopt::Std; #use CGI::Carp 'fatalsToBrowser'; require '/var/ipfire/general-functions.pl'; -require "${General::swroot}/geoip-functions.pl"; +require "${General::swroot}/location-functions.pl"; require "${General::swroot}/lang.pl"; require "${General::swroot}/header.pl"; # Libloc database handle. -my $libloc_db_handle = &GeoIP::init(); +my $libloc_db_handle = &Location::Functions::init(); use POSIX(); @@ -311,7 +311,7 @@ foreach $_ (@log) # Traffic from red if($srcaddr ne '') { # srcaddr is set - my $ccode = &GeoIP::lookup_country_code($libloc_db_handle, $srcaddr); + my $ccode = &Location::Functions::lookup_country_code($libloc_db_handle, $srcaddr); if ($ccode eq '') { $ccode = 'unknown'; } @@ -485,7 +485,7 @@ for($s=0;$s<$lines;$s++) my $fcode = lc($key[$s]); # Get flag icon for of the country. - my $flag_icon = &GeoIP::get_flag_icon($fcode); + my $flag_icon = &Location::Functions::get_flag_icon($fcode); if($flag_icon) { print "$key[$s]";