mirror of git://git.sysmocom.de/ofono
sim: new API to check for a UST service only
The existing service check API takes both SST and UST services and could inadvertently return success on a service if one (SST or UST) service did not exist. This adds an API specifically for checking for a UST service, and if the UST dir is not available it will return FALSE, rather than possibly returning true on some other SST service.
This commit is contained in:
parent
ee34967a52
commit
a8f609727d
|
@ -370,6 +370,8 @@ unsigned short __ofono_sms_get_next_ref(struct ofono_sms *sms);
|
|||
|
||||
#include <ofono/sim.h>
|
||||
|
||||
ofono_bool_t __ofono_sim_ust_service_available(struct ofono_sim *sim,
|
||||
int ust_service);
|
||||
ofono_bool_t __ofono_sim_service_available(struct ofono_sim *sim,
|
||||
int ust_service,
|
||||
int sst_service);
|
||||
|
|
|
@ -2289,6 +2289,15 @@ const unsigned char *ofono_sim_get_cphs_service_table(struct ofono_sim *sim)
|
|||
return sim->cphs_service_table;
|
||||
}
|
||||
|
||||
ofono_bool_t __ofono_sim_ust_service_available(struct ofono_sim *sim,
|
||||
int ust_service)
|
||||
{
|
||||
if (sim->efust)
|
||||
return sim_ust_is_available(sim->efust, sim->efust_length,
|
||||
ust_service);
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
ofono_bool_t __ofono_sim_service_available(struct ofono_sim *sim,
|
||||
int ust_service,
|
||||
int sst_service)
|
||||
|
|
Loading…
Reference in New Issue