morphyno has asked for the wisdom of the Perl Monks concerning the following question:
Can anyone suggest a method to handle in this type of exception? One work around is to check the availability of the device via system calls, but that solution won't always work for console servers.....$self -> {'_serial'} = Net::Appliance::Session -> Transport' => 'Seri +al'); eval { $self -> {'_serial'} -> connect('Name' => $uid, 'Password' => $pass, 'Parity' => 'none', 'Line' => $dev_id, 'Speed' => $baud_rate); }; if (@) {carp "Error: Device $dev_id is already in use};
|
|---|