Don't fail while enumerating readers, when a reader returns an error (just log).

This is useful with hubs that can power down individual ports: when a port is powered down, the reader is still visible to pcsc, but connecting to it returns an error.
This commit is contained in:
Heiko Schaefer 2021-11-29 21:26:16 +01:00
parent 9e9cddc225
commit a7fb5b2b2c
No known key found for this signature in database
GPG key ID: 4A849A1904CCBD7D

View file

@ -100,9 +100,12 @@ impl PcscClient {
continue; // try next reader continue; // try next reader
} }
Err(err) => { Err(err) => {
return Err(SmartcardError::SmartCardConnectionError( log::warn!(
err.to_string(), "Error connecting to card in reader: {:x?}",
)); err
);
continue;
} }
}; };