f_enc_IMSI_L3: Fix filler digit in *even* case

We actually need to add the filler digit 'F' if the number of digits
is even.  It is absent when the number of digits is odd.

Change-Id: Ic1353f4ea09bba3151636b94a99c8559e0289ffd
This commit is contained in:
Harald Welte 2018-01-24 20:53:21 +01:00
parent 2f562b1a70
commit ae1362544f
1 changed files with 2 additions and 2 deletions

View File

@ -47,10 +47,10 @@ private function f_enc_IMSI_L3(hexstring digits) return IMSI_L3 {
var integer len := lengthof(digits);
if (len rem 2 == 1) { /* modulo remainder */
l3.oddevenIndicator := '1'B;
l3.fillerDigit := '1111'B;
l3.fillerDigit := omit;
} else {
l3.oddevenIndicator := '0'B;
l3.fillerDigit := omit;
l3.fillerDigit := '1111'B;
}
l3.digits := digits;
return l3;