We need to check the ConnectionManager attached signal before
we are allowed to connect to the gprs context:
connmand[592]: plugins/ofono.c:cm_update_attached() /zte_0 Attached 0
[...]
connmand[592]: plugins/ofono.c:context_set_active() /zte_0 active 1
connmand[592]: plugins/ofono.c:set_property() /zte_0 path /zte_0/context1
org.ofono.ConnectionContext.Active
[...]
connmand[592]: plugins/ofono.c:cm_update_attached() /zte_0 Attached 1
Fixes BMC#25112
g_hash_table_replace(context_hash, g_strdup(context_path), modem);
- if (modem->valid_apn == TRUE &&
+ if (modem->valid_apn == TRUE && modem->attached == TRUE &&
has_interface(modem->interfaces,
OFONO_API_NETREG) == TRUE) {
add_network(modem);
if (modem->network != NULL)
return TRUE;
+ if (modem->attached == FALSE)
+ return TRUE;
+
if (has_interface(modem->interfaces,
OFONO_API_NETREG) == FALSE) {
return TRUE;