diff options
author | Francois Pons <fpons@mandriva.com> | 2002-08-26 12:52:17 +0000 |
---|---|---|
committer | Francois Pons <fpons@mandriva.com> | 2002-08-26 12:52:17 +0000 |
commit | 3401c296c098633573ae9dfb0a4138f99e0e1cc4 (patch) | |
tree | 4c74d204b1ec97908b1edc8faa0781572d0cad48 /perl-install | |
parent | 1916066643be8b9e94ef49a51807508e394b1f90 (diff) | |
download | drakx-backup-do-not-use-3401c296c098633573ae9dfb0a4138f99e0e1cc4.tar drakx-backup-do-not-use-3401c296c098633573ae9dfb0a4138f99e0e1cc4.tar.gz drakx-backup-do-not-use-3401c296c098633573ae9dfb0a4138f99e0e1cc4.tar.bz2 drakx-backup-do-not-use-3401c296c098633573ae9dfb0a4138f99e0e1cc4.tar.xz drakx-backup-do-not-use-3401c296c098633573ae9dfb0a4138f99e0e1cc4.zip |
avoid using serial_probe on non terminal device (ttyxx or ttySxx).
Diffstat (limited to 'perl-install')
-rw-r--r-- | perl-install/detect_devices.pm | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/perl-install/detect_devices.pm b/perl-install/detect_devices.pm index 634b4fe6c..43d3b785d 100644 --- a/perl-install/detect_devices.pm +++ b/perl-install/detect_devices.pm @@ -599,8 +599,12 @@ sub whatPrinterPort() { } sub probeSerialDevices { - #- make sure the device are created before probing. - foreach (0..3) { devices::make("/dev/ttyS$_") } + foreach (0..3) { + #- make sure the device are created before probing, + devices::make("/dev/ttyS$_"); + #- and make sure the device is a real terminal (major is 4). + int((stat "/dev/ttyS$_")[6]/256) == 4 or $serialprobe{"/dev/ttyS$_"} = undef; + } #- for device already probed, we can safely (assuming device are #- not moved during install :-) |