summaryrefslogtreecommitdiffstats
path: root/perl-install/detect_devices.pm
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>1999-11-06 09:10:11 +0000
committerFrancois Pons <fpons@mandriva.com>1999-11-06 09:10:11 +0000
commit152b0b998e117a4a79dd77d401df8cfc234574a5 (patch)
tree142ed19b54273ede98330a2b878e8e9a27567120 /perl-install/detect_devices.pm
parent07021694c8d96ab2205c9398a68d177e2d185f2a (diff)
downloaddrakx-backup-do-not-use-152b0b998e117a4a79dd77d401df8cfc234574a5.tar
drakx-backup-do-not-use-152b0b998e117a4a79dd77d401df8cfc234574a5.tar.gz
drakx-backup-do-not-use-152b0b998e117a4a79dd77d401df8cfc234574a5.tar.bz2
drakx-backup-do-not-use-152b0b998e117a4a79dd77d401df8cfc234574a5.tar.xz
drakx-backup-do-not-use-152b0b998e117a4a79dd77d401df8cfc234574a5.zip
*** empty log message ***
Diffstat (limited to 'perl-install/detect_devices.pm')
-rw-r--r--perl-install/detect_devices.pm8
1 files changed, 8 insertions, 0 deletions
diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm
index 7119fbd84..d932b4922 100644
--- a/perl-install/detect_devices.pm
+++ b/perl-install/detect_devices.pm
@@ -210,6 +210,14 @@ sub whatPrinterPort() {
grep { tryWrite($_)} qw(/dev/lp0 /dev/lp1 /dev/lp2);
}
+sub hasModem($) {
+ my ($device) = @_;
+ my %probe;
+ local *F; open F, "pnp_serial $device |";
+ foreach (<F>) { $probe{$1} = $2 if /^\s+(.*?)\s*:\s*\"(.*)\"\s*$/ }
+ $probe{CLASS} =~ /Modem/i && $probe{DESCRIPTION};
+}
+
#-######################################################################################
#- Wonderful perl :(
#-######################################################################################