** Description changed:

  Trying to connect using a GSM modem that lacks a SIM card does just give
  the user a general connection failure message without any hints about
  the missing SIM card.
  
  This can fool the user into thinking something other is wrong than the
  fact that he forgot to insert the SIM card, or inserted it improperly.
  
  Latest modemmanager master branch gives in log:
  
  Feb  2 20:21:24 marius-T1005 ModemManager[1105]: <warn>  Modem couldn't
  be initialized: Couldn't check unlock status: SIM failure
  
  but there is no indication to the user (nm-applet behaves as if mobile
- broadband is unavailable)
+ broadband is unavailable).
+ 
+ Seems I get (from "src/mm-error-helpers.c"):
+ 
+     { MM_MOBILE_EQUIPMENT_ERROR_SIM_FAILURE,
+ "simfailure",                                "SIM failure" },
+ 
+ but should have got:
+ 
+ { MM_MOBILE_EQUIPMENT_ERROR_SIM_NOT_INSERTED,
+ "simnotinserted",                            "SIM not inserted" }
+ 
+ Anyway (any of them should be enough hint to the user), it seems like
+ the  error state is not propagated (src/mm-broadband-modem.c):
+ 
+ static void
+ iface_modem_initialize_ready (MMBroadbandModem *self,
+                               GAsyncResult *result,
+                               InitializeContext *ctx)
+ {
+     GError *error = NULL;
+ 
+     /* If the modem interface fails to get initialized, we will move the modem
+      * to a FAILED state. Note that in this case we still export the 
interface. */
+     if (!mm_iface_modem_initialize_finish (MM_IFACE_MODEM (self), result, 
&error)) {
+         /* Report the new FAILED state */
+         mm_warn ("Modem couldn't be initialized: %s", error->message);
+         g_error_free (error);
+ 
+         mm_iface_modem_update_state (MM_IFACE_MODEM (self),
+                                      MM_MODEM_STATE_FAILED,
+                                      MM_MODEM_STATE_CHANGE_REASON_UNKNOWN);
+ 
+         /* Jump to the firmware step. We allow firmware switching even in 
failed
+          * state */
+         ctx->step = INITIALIZE_STEP_IFACE_FIRMWARE;
+         initialize_step (ctx);
+         return;
+     }

** Bug watch added: GNOME Bug Tracker #559488
   https://bugzilla.gnome.org/show_bug.cgi?id=559488

** Also affects: network-manager via
   https://bugzilla.gnome.org/show_bug.cgi?id=559488
   Importance: Unknown
       Status: Unknown

-- 
You received this bug notification because you are a member of Desktop
Packages, which is subscribed to network-manager in Ubuntu.
https://bugs.launchpad.net/bugs/1113703

Title:
  Trying to connect using a GSM modem without SIM card is not reported
  to user

Status in NetworkManager:
  Unknown
Status in “modemmanager” package in Ubuntu:
  New
Status in “network-manager” package in Ubuntu:
  New
Status in “network-manager-applet” package in Ubuntu:
  New

Bug description:
  Trying to connect using a GSM modem that lacks a SIM card does just
  give the user a general connection failure message without any hints
  about the missing SIM card.

  This can fool the user into thinking something other is wrong than the
  fact that he forgot to insert the SIM card, or inserted it improperly.

  Latest modemmanager master branch gives in log:

  Feb  2 20:21:24 marius-T1005 ModemManager[1105]: <warn>  Modem
  couldn't be initialized: Couldn't check unlock status: SIM failure

  but there is no indication to the user (nm-applet behaves as if mobile
  broadband is unavailable).

  Seems I get (from "src/mm-error-helpers.c"):

      { MM_MOBILE_EQUIPMENT_ERROR_SIM_FAILURE,
  "simfailure",                                "SIM failure" },

  but should have got:

  { MM_MOBILE_EQUIPMENT_ERROR_SIM_NOT_INSERTED,
  "simnotinserted",                            "SIM not inserted" }

  Anyway (any of them should be enough hint to the user), it seems like
  the  error state is not propagated (src/mm-broadband-modem.c):

  static void
  iface_modem_initialize_ready (MMBroadbandModem *self,
                                GAsyncResult *result,
                                InitializeContext *ctx)
  {
      GError *error = NULL;

      /* If the modem interface fails to get initialized, we will move the modem
       * to a FAILED state. Note that in this case we still export the 
interface. */
      if (!mm_iface_modem_initialize_finish (MM_IFACE_MODEM (self), result, 
&error)) {
          /* Report the new FAILED state */
          mm_warn ("Modem couldn't be initialized: %s", error->message);
          g_error_free (error);

          mm_iface_modem_update_state (MM_IFACE_MODEM (self),
                                       MM_MODEM_STATE_FAILED,
                                       MM_MODEM_STATE_CHANGE_REASON_UNKNOWN);

          /* Jump to the firmware step. We allow firmware switching even in 
failed
           * state */
          ctx->step = INITIALIZE_STEP_IFACE_FIRMWARE;
          initialize_step (ctx);
          return;
      }

To manage notifications about this bug go to:
https://bugs.launchpad.net/network-manager/+bug/1113703/+subscriptions

-- 
Mailing list: https://launchpad.net/~desktop-packages
Post to     : desktop-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~desktop-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to