gsm: ignore SIM-PUK2 unlock required

Device is functional without it; it's only required for stuff
we don't do yet.
This commit is contained in:
Dan Williams
2010-03-16 17:19:21 -07:00
parent 79bca53f21
commit 2c65e0ceaa

View File

@@ -884,9 +884,11 @@ enable (MMModem *modem,
GError *error = NULL;
const char *unlock;
/* If the device needs a PIN, deal with that now */
/* If the device needs a PIN, deal with that now, but we don't care
* about SIM-PUK2 since the device is operational without it.
*/
unlock = mm_modem_base_get_unlock_required (MM_MODEM_BASE (modem));
if (unlock) {
if (unlock && strcmp (unlock, "sim-puk2")) {
MMCallbackInfo *info;
info = mm_callback_info_new (modem, callback, user_data);
@@ -3088,9 +3090,11 @@ simple_state_machine (MMModem *modem, GError *error, gpointer user_data)
case SIMPLE_STATE_CHECK_PIN:
next_state = SIMPLE_STATE_ENABLE;
/* If we need a PIN, send it now */
/* If we need a PIN, send it now, but we don't care about SIM-PUK2
* since the device is operational without it.
*/
unlock = mm_modem_base_get_unlock_required (MM_MODEM_BASE (modem));
if (unlock) {
if (unlock && strcmp (unlock, "sim-puk2")) {
gboolean success = FALSE;
if (!strcmp (unlock, "sim-pin")) {