Harald Welte has submitted this change and it was merged.

Change subject: fix osmo_sccp_addr_dump(): actually print RI
......................................................................


fix osmo_sccp_addr_dump(): actually print RI

Adjust xua_test accordingly.

Change-Id: I93e0aa706867e7b1de7f7a6071e3c8af89772af0
---
M src/sccp_helpers.c
M tests/xua/xua_test.ok
2 files changed, 7 insertions(+), 7 deletions(-)

Approvals:
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/src/sccp_helpers.c b/src/sccp_helpers.c
index 471c9cb..db562db 100644
--- a/src/sccp_helpers.c
+++ b/src/sccp_helpers.c
@@ -282,7 +282,7 @@
 
        buf[0] = '\0';
 
-       append_to_buf(buf, &comma, "RI=7");
+       append_to_buf(buf, &comma, "RI=%d", addr->ri);
 
        if (addr->presence & OSMO_SCCP_ADDR_T_PC)
                append_to_buf(buf, &comma, "PC=%u", addr->pc);
diff --git a/tests/xua/xua_test.ok b/tests/xua/xua_test.ok
index ca8572a..12d817d 100644
--- a/tests/xua/xua_test.ok
+++ b/tests/xua/xua_test.ok
@@ -1,14 +1,14 @@
 digits='01234567' (8)
 digits='0123456' (7)
 sccp_addr_parse test case 0
-expected: RI=7,SSN=6,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919969679389)
-parsed:   RI=7,SSN=6,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919969679389)
+expected: RI=1,SSN=6,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919969679389)
+parsed:   RI=1,SSN=6,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919969679389)
 sccp_addr_parse test case 1
-expected: RI=7,SSN=8,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919869299992)
-parsed:   RI=7,SSN=8,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919869299992)
+expected: RI=1,SSN=8,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919869299992)
+parsed:   RI=1,SSN=8,GTI=4,GT=(TT=0,NPL=1,NAI=4,DIG=919869299992)
 sccp_addr_parse test case 2
-expected: RI=7,SSN=254,GTI=0
-parsed:   RI=7,SSN=254,GTI=0
+expected: RI=2,SSN=254,GTI=0
+parsed:   RI=2,SSN=254,GTI=0
 Testing Decoded GT -> SUA encoding
 IN: TT=0,NPL=1,NAI=4,DIG=919969679389
     
0400000001000000040000003931393936393637393338390000000000000000000000000000000000000000

-- 
To view, visit https://gerrit.osmocom.org/3364
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I93e0aa706867e7b1de7f7a6071e3c8af89772af0
Gerrit-PatchSet: 4
Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofm...@sysmocom.de>
Gerrit-Reviewer: Harald Welte <lafo...@gnumonks.org>
Gerrit-Reviewer: Jenkins Builder

Reply via email to