Skip to content

Commit

Permalink
[ril] Use ofono_sim_read_path() in case of reading EFpbr from USIM. F…
Browse files Browse the repository at this point in the history
…ixes JB#54420

There is an issue when some of the Mediatek modems do not accept empty
path to the EFpbr file on the USIM and do reset themselves.
This fix appends usim_path to the GET DATA command when it comes to
exporting phonebook from SIM card and prevents crashes like described
one.
  • Loading branch information
bmigunov committed May 25, 2021
1 parent f91df7f commit eddcb88
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion ofono/drivers/ril/ril_phonebook.c
Expand Up @@ -998,8 +998,9 @@ static void ril_export_entries(struct ofono_phonebook *pb,
pbd->df_path = usim_path;
pbd->df_size = sizeof(usim_path);

ofono_sim_read(pbd->sim_context, SIM_EFPBR_FILEID,
ofono_sim_read_path(pbd->sim_context, SIM_EFPBR_FILEID,
OFONO_SIM_FILE_STRUCTURE_FIXED,
pbd->df_path, pbd->df_size,
pb_reference_data_cb, pb);
}

Expand Down

0 comments on commit eddcb88

Please sign in to comment.