diff options
author | Neels Hofmeyr <nhofmeyr@sysmocom.de> | 2017-03-04 21:09:12 +0100 |
---|---|---|
committer | Neels Hofmeyr <nhofmeyr@sysmocom.de> | 2017-03-09 18:34:14 +0100 |
commit | e38de9dd4f2649a0c4e4a16a1f199b48d5a2d2ff (patch) | |
tree | c3745f93fad82ae8fa32bd0bbeb178952d87105e /openbsc/src/libvlr | |
parent | be81545e401c2da91cfc98b308f2d843dbbb3950 (diff) |
fix: vlr: clear last_tuple when receiving auth tuples
When receiving more than one auth tuple during AUTS resync, the VLR would go on
to send the second tuple instead of the first. The unit test didn't catch that
because its fake HLR message contained only one tuple.
Adjust the test to send two tuples to catch this error.
Fix the code to clear vlr_subscr->last_tuple whenever new auth tuples are
received.
Change-Id: I1f84e7d2619aa8d9a0dcdfb50745feeb040264b9
Diffstat (limited to 'openbsc/src/libvlr')
-rw-r--r-- | openbsc/src/libvlr/vlr.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/openbsc/src/libvlr/vlr.c b/openbsc/src/libvlr/vlr.c index db874f298..a8404b246 100644 --- a/openbsc/src/libvlr/vlr.c +++ b/openbsc/src/libvlr/vlr.c @@ -568,6 +568,9 @@ void vlr_subscr_update_tuples(struct vlr_subscr *vsub, /* FIXME what now? */ // vlr_subscr_cancel(vsub, GMM_CAUSE_GSM_AUTH_UNACCEPT); ? } + + /* New tuples means last_tuple becomes invalid */ + vsub->last_tuple = NULL; } /* Handle SendAuthInfo Result/Error from HLR */ |