From 13c0fb79103e4030d7b2999b4edc1c4686755919 Mon Sep 17 00:00:00 2001 From: Stefan Schantl Date: Thu, 5 Dec 2019 17:17:42 +0100 Subject: [PATCH] ipinfo.cgi: Use new location lookup method. Signed-off-by: Stefan Schantl --- html/cgi-bin/ipinfo.cgi | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/html/cgi-bin/ipinfo.cgi b/html/cgi-bin/ipinfo.cgi index b756a24d2a..6465bc3e4c 100644 --- a/html/cgi-bin/ipinfo.cgi +++ b/html/cgi-bin/ipinfo.cgi @@ -52,7 +52,8 @@ if (&General::validip($addr)) { if (!$hostname) { $hostname = $Lang::tr{'lookup failed'}; } # enumerate GeoIP information for IP address... - my $ccode = &GeoIP::lookup($addr); + my $db_handle = &GeoIP::init(); + my $ccode = &GeoIP::lookup_country_code($db_handle, $addr); my $flag_icon = &GeoIP::get_flag_icon($ccode); my $sock = new IO::Socket::INET ( PeerAddr => $whoisname, PeerPort => 43, Proto => 'tcp'); -- 2.39.5