pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-iuh/+/43809?usp=email )
Change subject: sigtran: N-NOTICE.ind: Use proper SCCP-User return reason ......................................................................
sigtran: N-NOTICE.ind: Use proper SCCP-User return reason
Until recently, libosmo-sigtran was incorrectly expecting low-level wire-format cause in N-NOTICE.ind. Nowadays it supports specific reason values in the SCCP-User SAP, so use those instead. This change is backward-compatible since the value for both enums are the same as per specs.
Change-Id: Ic49e3d2776f7609ef325056bd5431fe36f5a8d53 Related: OS#2601 --- M TODO-RELEASE M src/iu_client.c 2 files changed, 5 insertions(+), 5 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-iuh refs/changes/09/43809/1
diff --git a/TODO-RELEASE b/TODO-RELEASE index b6d61b1..5e970b9 100644 --- a/TODO-RELEASE +++ b/TODO-RELEASE @@ -8,3 +8,4 @@ # If any interfaces have been removed or changed since the last public release: c:r:0. #library what description / commit summary line libosmo-sigtran >2.3.0 OSMO_SCCP_REL_REASON_NSU_* +libosmo-sigtran >2.3.0 OSMO_SCCP_RETURN_REASON_*, osmo_sccp_return_reason_name() diff --git a/src/iu_client.c b/src/iu_client.c index ae87460..acb9d2f 100644 --- a/src/iu_client.c +++ b/src/iu_client.c @@ -35,7 +35,6 @@ #include <osmocom/gprs/gprs_msgb.h> #include <osmocom/sigtran/sccp_sap.h> #include <osmocom/sigtran/sccp_helpers.h> -#include <osmocom/sccp/sccp_types.h> #include <osmocom/ranap/ranap_common_cn.h> #include <osmocom/ranap/ranap_ies_defs.h> #include <osmocom/ranap/ranap_msg_factory.h> @@ -1031,12 +1030,12 @@
LOGPIU(LOGL_DEBUG, "(calling_addr=%s) N-NOTICE.ind cause=%u='%s' importance=%u\n", osmo_sccp_addr_dump(&ni->calling_addr), - ni->cause, osmo_sccp_return_cause_name(ni->cause), + ni->cause, osmo_sccp_return_reason_name(ni->cause), ni->importance);
switch (ni->cause) { - case SCCP_RETURN_CAUSE_SUBSYSTEM_CONGESTION: - case SCCP_RETURN_CAUSE_NETWORK_CONGESTION: + case OSMO_SCCP_RETURN_REASON_SUBSYSTEM_CONGESTION: + case OSMO_SCCP_RETURN_REASON_NETWORK_CONGESTION: /* Transient failures (hopefully), keep going. */ return; default: @@ -1051,7 +1050,7 @@ LOGPIU(LOGL_NOTICE, "RNC %s now unreachable: N-NOTICE.ind cause=%u='%s' importance=%u\n", osmo_rnc_id_name(&rnc->rnc_id), - ni->cause, osmo_sccp_return_cause_name(ni->cause), + ni->cause, osmo_sccp_return_reason_name(ni->cause), ni->importance); llist_for_each_entry_safe(ue_ctx, ue_ctx_tmp, &ue_conn_ctx_list, list) { if (ue_ctx->rnc != rnc)