nerves-networking / vintage_net_qmi

VintageNet technology support for QMI mobile connections
Apache License 2.0
11 stars 3 forks source link

Fix crash when trying to connect w/o an ICCID #194

Closed fhunleth closed 3 months ago

fhunleth commented 3 months ago

If there are problems reading the ICCID off the SIM card, the APN selection code repeatedly raises an exception.

This isn't good. It would be much better to log an error and raise an alarm in a more general way.

This updates the code to validate the ICCID before trying to select an APN. The code in the with was really hard to read, so this modifies function calls to make it easier. The modifications are not intended to change any semantics.

fhunleth commented 3 months ago

@doawoo I can't add you as a reviewer, but did this work for you?