sim: Initialize card_slot_count and active_card_slot

Initialize both to 1 so that SimManager does not erroneously show
ActiveCardSlot as 0 for drivers that do not (yet) setup these values.
This commit is contained in:
Denis Kenzior 2019-03-28 21:05:04 -05:00
parent ab4e5d0852
commit c5cb6f7a3c
1 changed files with 3 additions and 0 deletions

View File

@ -3383,6 +3383,9 @@ struct ofono_sim *ofono_sim_create(struct ofono_modem *modem,
for (i = 0; i < OFONO_SIM_PASSWORD_INVALID; i++)
sim->pin_retries[i] = -1;
sim->active_card_slot = 1;
sim->card_slot_count = 1;
for (l = g_drivers; l; l = l->next) {
const struct ofono_sim_driver *drv = l->data;