aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/tests/gbproxy/gbproxy_test.c
diff options
context:
space:
mode:
authorJacob Erlbeck <jerlbeck@sysmocom.de>2014-09-15 11:46:42 +0200
committerJacob Erlbeck <jerlbeck@sysmocom.de>2014-09-19 10:49:12 +0200
commit16a3cd3847413a1b6e29d82a6aacd23300f7af5f (patch)
tree60bf412a84484fe03e7053bb7e91b2596432b7ad /openbsc/tests/gbproxy/gbproxy_test.c
parent7430da621a25337d614cd08acb578905aa52337d (diff)
gbproxy: Avoid multiple tlli_info entries with the same IMSI
Currently it is possible to create several tlli_info entries with the same IMSI. This patch disables this by adding a check before the imsi field is updated. Sponsored-by: On-Waves ehf
Diffstat (limited to 'openbsc/tests/gbproxy/gbproxy_test.c')
-rw-r--r--openbsc/tests/gbproxy/gbproxy_test.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/openbsc/tests/gbproxy/gbproxy_test.c b/openbsc/tests/gbproxy/gbproxy_test.c
index c4ebc73ea..cfbe68859 100644
--- a/openbsc/tests/gbproxy/gbproxy_test.c
+++ b/openbsc/tests/gbproxy/gbproxy_test.c
@@ -2959,10 +2959,10 @@ static void test_gbproxy_keep_info()
dump_peers(stdout, 0, 0, &gbcfg);
- /* TODO: There is one entry with this TLLI left (since there were 2
- * before the detach precedure started. Add assertions when
- * this is fixed.
- */
+ OSMO_ASSERT(!gbproxy_find_tlli(peer, local_tlli));
+ tlli_info = gbproxy_find_tlli_by_imsi(peer, imsi, sizeof(imsi));
+ OSMO_ASSERT(tlli_info);
+ OSMO_ASSERT(tlli_info->is_deregistered);
dump_global(stdout, 0);