mirror of git://git.sysmocom.de/ofono
Fix: Properly update technologies
When current operator is reported, update the technology list if the tech information is available
This commit is contained in:
parent
a53440d648
commit
252fd9eb52
|
@ -1128,9 +1128,16 @@ static void current_operator_callback(const struct ofono_error *error,
|
||||||
network_operator_compare);
|
network_operator_compare);
|
||||||
|
|
||||||
if (op) {
|
if (op) {
|
||||||
set_network_operator_status(op->data, OPERATOR_STATUS_CURRENT);
|
struct network_operator_data *opd = op->data;
|
||||||
set_network_operator_techs(op->data, current->tech);
|
unsigned int techs = opd->techs;
|
||||||
set_network_operator_name(op->data, current->name);
|
|
||||||
|
if (current->tech != -1) {
|
||||||
|
techs |= 1 << current->tech;
|
||||||
|
set_network_operator_techs(opd, techs);
|
||||||
|
}
|
||||||
|
|
||||||
|
set_network_operator_status(opd, OPERATOR_STATUS_CURRENT);
|
||||||
|
set_network_operator_name(opd, current->name);
|
||||||
|
|
||||||
if (netreg->current_operator == op->data)
|
if (netreg->current_operator == op->data)
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue