From 890c98037f7d83af681a70930499de0ded25be4c Mon Sep 17 00:00:00 2001 From: Olivier Blin Date: Wed, 13 Jul 2005 06:32:09 +0000 Subject: add has_wireless --- perl-install/detect_devices.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'perl-install') diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm index b84d940af..eeec05624 100644 --- a/perl-install/detect_devices.pm +++ b/perl-install/detect_devices.pm @@ -582,6 +582,7 @@ sub is_wireless_interface { #- i.e interfaces for which get_wireless_stats() is available c::isNetDeviceWirelessAware($interface) || -e "/sys/class/net/$interface/wireless"; } +sub has_wireless() { any { is_wireless_interface($_) } getNet() } sub is_bridge_interface { my ($interface) = @_; @@ -916,7 +917,7 @@ sub matching_type { if ($type =~ /laptop/i) { return isLaptop(); } elsif ($type =~ /wireless/i) { - return any { is_wireless_interface($_) } getNet(); + return has_wireless(); } } -- cgit v1.2.1