Fix: Go to online state if set_online is NULL

This commit is contained in:
Denis Kenzior 2010-05-26 17:45:06 -05:00
parent 7705cebd3f
commit 5a24916aae
1 changed files with 9 additions and 0 deletions

View File

@ -1269,6 +1269,15 @@ static void modem_sim_ready(void *user, enum ofono_sim_state new_state)
break;
case OFONO_SIM_STATE_READY:
modem_change_state(modem, MODEM_STATE_OFFLINE);
/*
* If we don't have the set_online method, also proceed
* straight to the online state
*/
if (modem->driver->set_online == NULL)
modem_change_state(modem, MODEM_STATE_ONLINE);
break;
}
}