pespin has submitted this change. ( 
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35743?usp=email )

Change subject: GSUP: Fix spare and pdp_type_org fields swapped in PDPAddress IE
......................................................................

GSUP: Fix spare and pdp_type_org fields swapped in PDPAddress IE

A recent commit added records to separate 2 binary octets into known
fields, but 2 fields filling 1 byte were actually written swapped. Fix
it now.

Fixes: 7b7a1e8ed16e41d95aed72a15f4ddf1857566b2e
Change-Id: I884bddb0e1e5f1cfc5615c11d6c7d602d0df9224
---
M library/GSUP_Templates.ttcn
M library/GSUP_Types.ttcn
2 files changed, 21 insertions(+), 7 deletions(-)

Approvals:
  Jenkins Builder: Verified
  fixeria: Looks good to me, but someone else must approve
  osmith: Looks good to me, approved




diff --git a/library/GSUP_Templates.ttcn b/library/GSUP_Templates.ttcn
index 68e4fd1..291b59a 100644
--- a/library/GSUP_Templates.ttcn
+++ b/library/GSUP_Templates.ttcn
@@ -61,8 +61,8 @@

 template (value) GSUP_PDP_Address ts_GSUP_PDP_Address_IPv4(template (omit) 
OCT4 ip_addr) := {
        ipv4 := {
-               pdp_typeorg := '0001'B,
                spare := '1111'B,
+               pdp_typeorg := '0001'B,
                pdp_typenum := '21'O,
                ipv4_address := ip_addr
        }
diff --git a/library/GSUP_Types.ttcn b/library/GSUP_Types.ttcn
index 07356f7..0bab1d6 100644
--- a/library/GSUP_Types.ttcn
+++ b/library/GSUP_Types.ttcn
@@ -207,30 +207,30 @@
                      other, OTHERWISE;)" };

 type record  GSUP_PDP_Address_IPv4 {
-       BIT4    pdp_typeorg,
        BIT4    spare,
+       BIT4    pdp_typeorg,
        OCT1    pdp_typenum,
        OCT4    ipv4_address optional
 };

 type record GSUP_PDP_Address_IPv6 {
-       BIT4    pdp_typeorg,
-       BIT4    spare,
+       BIT4    spare,
+       BIT4    pdp_typeorg,
        OCT1    pdp_typenum,
        OCT16   ipv6_address optional
 };

 type record GSUP_PDP_Address_IPv4v6 {
-       BIT4    pdp_typeorg,
-       BIT4    spare,
+       BIT4    spare,
+       BIT4    pdp_typeorg,
        OCT1    pdp_typenum,
        OCT4    ipv4_address optional,
        OCT16   ipv6_address optional
 };

 type record  GSUP_PDP_Address_unknown {
-       BIT4    pdp_typeorg,
        BIT4    spare,
+       BIT4    pdp_typeorg,
        OCT1    pdp_typenum,
        octetstring addr optional
 };

--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/35743?usp=email
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I884bddb0e1e5f1cfc5615c11d6c7d602d0df9224
Gerrit-Change-Number: 35743
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <[email protected]>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <[email protected]>
Gerrit-Reviewer: osmith <[email protected]>
Gerrit-Reviewer: pespin <[email protected]>
Gerrit-MessageType: merged

Reply via email to