mirror of git://git.sysmocom.de/ofono
network.c: notify_status_watches: check for NULL
In rare cases when ofono_netreg_status_notify() is called before ofono_netreg_register() netreg->status_watches is NULL.
This commit is contained in:
parent
4590c695e0
commit
e98f683309
|
@ -1186,6 +1186,9 @@ static void notify_status_watches(struct ofono_netreg *netreg)
|
|||
const char *mcc = NULL;
|
||||
const char *mnc = NULL;
|
||||
|
||||
if (netreg->status_watches == NULL)
|
||||
return;
|
||||
|
||||
if (netreg->current_operator) {
|
||||
mcc = netreg->current_operator->mcc;
|
||||
mnc = netreg->current_operator->mnc;
|
||||
|
|
Loading…
Reference in New Issue