]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - html/cgi-bin/logs.cgi/showrequestfromcountry.dat
logs.cgi/showrequestfromcountry.dat: Proper lookup country code.
[people/pmueller/ipfire-2.x.git] / html / cgi-bin / logs.cgi / showrequestfromcountry.dat
index 2a246ec60e9fbe5a7c5af804057796ed7bc99c9b..f81994f870ccdd658c22cb764240ee99cd5ad00f 100644 (file)
@@ -218,7 +218,7 @@ if ($multifile) {
                                # extract ipv4 and ipv6 address
                                elsif (($_ =~ /SRC\=(([\d]{1,3})(\.([\d]{1,3})){3})/) or ($_ =~ /SRC\=(([0-9a-fA-F]{0,4})(\:([0-9a-fA-F]{0,4})){2,7})/)) {
                                        my $srcaddr=$1;
-                                       my $ccode = $gi->country_code_by_name($srcaddr);
+                                       my $ccode = &Location::Functions::lookup_country_code($srcaddr);
                                        if($ccode eq uc($country)){
                                                # or srcaddr matches country code
                                                $log[$lines] = $_;