diff options
author | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-08-18 11:55:03 +0200 |
---|---|---|
committer | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-08-18 11:55:03 +0200 |
commit | 2b349b5d33050f6484c375e545ecb9f05a6be961 (patch) | |
tree | b7969962b60bc2b0dd27f2c56e3dd8501ddb792b /src/tbf.cpp | |
parent | ebebad1c92e8bcbe28780b4d5ee2ac32091089ff (diff) |
ms: Move MS information merging to GprsMS
Currently the merging of the meta information (MS class, IMSI) takes
place in gprs_rlcmac_tbf::merge_and_clear_ms(). This makes it
difficult to merge the internal state and does not directly relate to
TBFs anyway.
This commit moves this into a new method GprsMs::merge_old_ms.
Sponsored-by: On-Waves ehf
Diffstat (limited to 'src/tbf.cpp')
-rw-r--r-- | src/tbf.cpp | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/src/tbf.cpp b/src/tbf.cpp index 9f873dc3..c63d7cc2 100644 --- a/src/tbf.cpp +++ b/src/tbf.cpp @@ -164,14 +164,6 @@ void gprs_rlcmac_tbf::merge_and_clear_ms(GprsMs *old_ms) GprsMs::Guard guard_old(old_ms); - if (strlen(ms()->imsi()) == 0 && strlen(old_ms->imsi()) != 0) { - ms()->set_imsi(old_ms->imsi()); - old_ms->set_imsi(""); - } - - if (!ms()->ms_class() && old_ms->ms_class()) - ms()->set_ms_class(old_ms->ms_class()); - /* Clean up the old MS object */ /* TODO: Use timer? */ if (old_ms->ul_tbf() && old_ms->ul_tbf()->T == 0) { @@ -197,7 +189,7 @@ void gprs_rlcmac_tbf::merge_and_clear_ms(GprsMs *old_ms) } } - old_ms->reset(); + ms()->merge_old_ms(old_ms); } void gprs_rlcmac_tbf::update_ms(uint32_t tlli, enum gprs_rlcmac_tbf_direction dir) |