Change in osmo-msc[master]: libmsc/gsm_09_11.c: properly indicate transaction errors

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Vadim Yanitskiy gerrit-no-reply at lists.osmocom.org
Tue Jun 12 04:43:59 UTC 2018


Vadim Yanitskiy has uploaded this change for review. ( https://gerrit.osmocom.org/9554


Change subject: libmsc/gsm_09_11.c: properly indicate transaction errors
......................................................................

libmsc/gsm_09_11.c: properly indicate transaction errors

Previously it was intended that we are always parsing the
whole GSM 04.80 message, including the Invoke ID. But
there is no need to do that, since we are going to
forward the Facility IE payload to HLR in near future.

Moreover, there was a mistake (my bad) - transaction is
being established before parsing of the message, so the
req structure remains uninitialized until that.

Let's just send RELEASE COMPLETE message without any Cause or
Facility IEs. We could indicate a problem using the first one,
but according to GSM TS 04.80, the Cause IE only makes sense
when "its functional handling is specified in the service
description or GSM TS 09.11".

Change-Id: Iecba2dccada9bbcdeb3a9dfd868719aeedc07022
---
M src/libmsc/gsm_09_11.c
1 file changed, 6 insertions(+), 5 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/54/9554/1

diff --git a/src/libmsc/gsm_09_11.c b/src/libmsc/gsm_09_11.c
index 8f7e54f..fc588f5 100644
--- a/src/libmsc/gsm_09_11.c
+++ b/src/libmsc/gsm_09_11.c
@@ -94,9 +94,9 @@
 			LOGP(DMM, LOGL_ERROR, "Unexpected message (msg_type=%s), "
 				"transaction is not allocated yet\n",
 				gsm48_pdisc_msgtype_name(pdisc, msg_type));
-			gsm0480_send_ussd_reject(conn, &req,
-				GSM_0480_PROBLEM_CODE_TAG_GENERAL,
-				GSM_0480_GEN_PROB_CODE_UNRECOGNISED);
+			gsm48_tx_simple(conn,
+				GSM48_PDISC_NC_SS | (tid << 4),
+				GSM0480_MTYPE_RELEASE_COMPLETE);
 			return -EINVAL;
 		}
 
@@ -105,8 +105,9 @@
 			pdisc, tid, new_callref++);
 		if (!trans) {
 			DEBUGP(DMM, " -> No memory for trans\n");
-			gsm0480_send_ussd_return_error(conn, &req,
-				GSM0480_ERR_CODE_SYSTEM_FAILURE);
+			gsm48_tx_simple(conn,
+				GSM48_PDISC_NC_SS | (tid << 4),
+				GSM0480_MTYPE_RELEASE_COMPLETE);
 			return -ENOMEM;
 		}
 

-- 
To view, visit https://gerrit.osmocom.org/9554
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iecba2dccada9bbcdeb3a9dfd868719aeedc07022
Gerrit-Change-Number: 9554
Gerrit-PatchSet: 1
Gerrit-Owner: Vadim Yanitskiy <axilirator at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20180612/45ba93bd/attachment.htm>


More information about the gerrit-log mailing list