diff options
author | Aleksander Morgado <aleksander@aleksander.es> | 2018-12-06 14:14:58 +0100 |
---|---|---|
committer | Dan Williams <dcbw@redhat.com> | 2018-12-07 16:23:52 +0000 |
commit | 27276bf8626894b3814791d0e170ee56c177e3f0 (patch) | |
tree | 7e0e37b3b79c00190f8c648a26e8099b15613386 /src | |
parent | f4941ede665bffbf1cd25266781da6625fb09fb0 (diff) |
iface-modem: remove redundant logic to update failed state
When the MMIfaceModem initialization returns with the SIM_NOT_INSERTED
error, the base logic is already updating the modem failed reason to
SIM_MISSING. There is no need to do that explicitly for the case where
SIM hot swap is supported.
Diffstat (limited to 'src')
-rw-r--r-- | src/mm-iface-modem.c | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/src/mm-iface-modem.c b/src/mm-iface-modem.c index 03a680dd..4c952684 100644 --- a/src/mm-iface-modem.c +++ b/src/mm-iface-modem.c @@ -4984,21 +4984,7 @@ interface_initialization_step (GTask *task) G_CALLBACK (handle_factory_reset), self); - if (ctx->fatal_error) { - if (g_error_matches (ctx->fatal_error, - MM_MOBILE_EQUIPMENT_ERROR, - MM_MOBILE_EQUIPMENT_ERROR_SIM_NOT_INSERTED)) { - gboolean is_sim_hot_swap_supported = FALSE; - - g_object_get (self, - MM_IFACE_MODEM_SIM_HOT_SWAP_SUPPORTED, &is_sim_hot_swap_supported, - NULL); - - if (is_sim_hot_swap_supported) { - mm_iface_modem_update_failed_state (self, MM_MODEM_STATE_FAILED_REASON_SIM_MISSING); - } - } - } else { + if (!ctx->fatal_error) { /* We are done without errors! * Handle method invocations */ g_signal_connect (ctx->skeleton, |