gbproxy: Unregister IMSI from BSSGP before termination of ConnHdlr

Otherwise we may run into problems where the BSSGP_Emulation still
has references to longer existing components in its ClientTable.

Change-Id: Iee54e93e6ae1b3e40f502d5ba2499e9eb03bf203
This commit is contained in:
Harald Welte 2021-01-16 12:50:56 +01:00
parent 2ecbca8080
commit b33fb59b49
1 changed files with 12 additions and 0 deletions

View File

@ -713,6 +713,18 @@ runs on BSSGP_ConnHdlr {
/* call the user-supplied test case function */
fn.apply(id);
for (i := 0; i < NUM_SGSN; i := i+1) {
if (SGSN_PROC[i].checkstate("Connected")) {
f_client_unregister(g_pars.imsi, SGSN_PROC[i])
}
}
for (i := 0; i < NUM_PCU; i := i+1) {
if (PCU_PROC[i].checkstate("Connected")) {
f_client_unregister(g_pars.imsi, PCU_PROC[i])
}
}
}
private function f_client_register(hexstring imsi, OCT4 tlli, BSSGP_PROC_PT PT)