diff options
author | Vadim Yanitskiy <axilirator@gmail.com> | 2020-01-10 00:23:10 +0100 |
---|---|---|
committer | laforge <laforge@osmocom.org> | 2020-01-10 16:03:27 +0000 |
commit | ae747741388d3e3bb538332f26d49b20ac9aee69 (patch) | |
tree | d277bff678e1253a2d466d903258658df9dfad6b /library/RAN_Emulation.ttcnpp | |
parent | 70d15bf48f500c26357f82ad03a2dd7ade9fecfe (diff) |
MSC: f_ran_register_imsi(): allow passing omit as TMSI
Change-Id: I6dd2f77283a79e83f028115f4cc42f05db885838
Diffstat (limited to 'library/RAN_Emulation.ttcnpp')
-rw-r--r-- | library/RAN_Emulation.ttcnpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/library/RAN_Emulation.ttcnpp b/library/RAN_Emulation.ttcnpp index 891de09d..b54d6e4d 100644 --- a/library/RAN_Emulation.ttcnpp +++ b/library/RAN_Emulation.ttcnpp @@ -1444,8 +1444,17 @@ runs on RAN_Emulation_CT { } /* helper function for clients to register their IMSI/TMSI */ -function f_ran_register_imsi(hexstring imsi, OCT4 tmsi) +function f_ran_register_imsi(hexstring imsi, template (omit) OCT4 tmsi_or_omit) runs on RAN_ConnHdlr { + var OCT4 tmsi; + + /* Resolve omit to a special reserved value */ + if (istemplatekind(tmsi_or_omit, "omit")) { + tmsi := 'FFFFFFFF'O; + } else { + tmsi := valueof(tmsi_or_omit); + } + BSSAP_PROC.call(RAN_register_imsi:{imsi, tmsi, self}) { [] BSSAP_PROC.getreply(RAN_register_imsi:{?,?,?}) {}; } |