Changes on enb::stop and rem_user to avoid segfaults

This commit is contained in:
Ismael Gomez 2017-09-29 13:38:47 +02:00
parent b625910b55
commit c23ceae2ec
2 changed files with 5 additions and 4 deletions

View File

@ -228,13 +228,13 @@ void enb::stop()
{ {
if(started) if(started)
{ {
gtpu.stop();
phy.stop(); phy.stop();
mac.stop(); mac.stop();
usleep(1e5); usleep(100000);
rlc.stop(); rlc.stop();
pdcp.stop(); pdcp.stop();
gtpu.stop();
rrc.stop(); rrc.stop();
usleep(1e5); usleep(1e5);

View File

@ -224,6 +224,7 @@ void rrc::rem_user(uint16_t rnti)
rrc_log->info("Disconnecting rnti=0x%x.\n", rnti); rrc_log->info("Disconnecting rnti=0x%x.\n", rnti);
/* **Caution** order of removal here is imporant: from bottom to top */ /* **Caution** order of removal here is imporant: from bottom to top */
mac->ue_rem(rnti); // MAC handles PHY mac->ue_rem(rnti); // MAC handles PHY
usleep(50000);
rlc->rem_user(rnti); rlc->rem_user(rnti);
pdcp->rem_user(rnti); pdcp->rem_user(rnti);
gtpu->rem_user(rnti); gtpu->rem_user(rnti);