diff options
Diffstat (limited to 'lib/network/tools.pm')
-rw-r--r-- | lib/network/tools.pm | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/network/tools.pm b/lib/network/tools.pm index de8261d..04bd343 100644 --- a/lib/network/tools.pm +++ b/lib/network/tools.pm @@ -264,8 +264,7 @@ sub host_hex_to_dotted { sub get_routes() { my %routes; my @routes = cat_("/proc/net/route"); - require any; - @routes = reverse(@routes) if any::cmp_kernel_versions(c::kernel_version(), "2.6.39") >= 0; + @routes = reverse(@routes) if common::cmp_kernel_versions(c::kernel_version(), "2.6.39") >= 0; foreach (@routes) { if (/^(\S+)\s+([0-9A-F]+)\s+([0-9A-F]+)\s+[0-9A-F]+\s+\d+\s+\d+\s+(\d+)\s+([0-9A-F]+)/) { if (defined $3) { $routes{$1}{gateway} = hex($3) ? host_hex_to_dotted($3) : $routes{$1}{network} } |