forked from acouzens/open5gs
[AUSF] Fixed crash due to ausf_ue_add (#2637)
This commit is contained in:
parent
5a220f1a83
commit
445bf26ef2
|
@ -129,7 +129,6 @@ void ausf_state_operational(ogs_fsm_t *s, ausf_event_t *e)
|
||||||
if (!ausf_ue) {
|
if (!ausf_ue) {
|
||||||
ausf_ue = ausf_ue_add(
|
ausf_ue = ausf_ue_add(
|
||||||
message.AuthenticationInfo->supi_or_suci);
|
message.AuthenticationInfo->supi_or_suci);
|
||||||
ogs_assert(ausf_ue);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -126,6 +126,10 @@ ausf_ue_t *ausf_ue_add(char *suci)
|
||||||
ogs_assert(suci);
|
ogs_assert(suci);
|
||||||
|
|
||||||
ogs_pool_alloc(&ausf_ue_pool, &ausf_ue);
|
ogs_pool_alloc(&ausf_ue_pool, &ausf_ue);
|
||||||
|
if (!ausf_ue) {
|
||||||
|
ogs_error("ogs_pool_alloc() failed");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
ogs_assert(ausf_ue);
|
ogs_assert(ausf_ue);
|
||||||
memset(ausf_ue, 0, sizeof *ausf_ue);
|
memset(ausf_ue, 0, sizeof *ausf_ue);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue