fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/33931 )
Change subject: gsm48_ie: fix gsm48_encode_bearer_cap(): encode bcap->data.transp ......................................................................
gsm48_ie: fix gsm48_encode_bearer_cap(): encode bcap->data.transp
Currently this function is hard-coding the "Connection element (octet 6c)" (see Table 10.5.101h/3GPP TS 24.008) to "Transparent" (0). This breaks non-transparent data calls.
Use the value from bcap->data.transp. The decoding equivalent of this function needs no changes, it does populate this field already.
Change-Id: I7339908864e8a2aef6f2b48a108650167e413c7f Related: OS#6110, OS#4394 --- M src/gsm/gsm48_ie.c 1 file changed, 20 insertions(+), 1 deletion(-)
git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/31/33931/1
diff --git a/src/gsm/gsm48_ie.c b/src/gsm/gsm48_ie.c index e431e4f..0cdcb7c 100644 --- a/src/gsm/gsm48_ie.c +++ b/src/gsm/gsm48_ie.c @@ -351,7 +351,9 @@ lv[i++] = (bcap->data.parity & 7) | ((bcap->data.interm_rate & 3) << 5); /* octet 6c */ - lv[i] = 0x80 | (bcap->data.modem_type & 0x1f); + lv[i] = 0x80 | + ((bcap->data.transp & 3) << 5) | + (bcap->data.modem_type & 0x1f); break; default: return -EINVAL;