From 3eff2c5be53c6044375927338a5eab6fbe380d36 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Tue, 16 May 2017 19:00:29 +0200 Subject: [PATCH] SCCP Emulation: Fix CC optional user data A SCCP CC can optionally contain userData. The code so far simply dropped any such data, and didn't pass it along in the N-CONNCET.cfm primitive. Let's fix that. --- SCCP_CNL113341/src/SCCP_Emulation.ttcn | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/SCCP_CNL113341/src/SCCP_Emulation.ttcn b/SCCP_CNL113341/src/SCCP_Emulation.ttcn index 5e269cc51..af423a57f 100644 --- a/SCCP_CNL113341/src/SCCP_Emulation.ttcn +++ b/SCCP_CNL113341/src/SCCP_Emulation.ttcn @@ -3768,6 +3768,16 @@ group SCCPFunctions log(pl_PDU_SCCP_ConnectionConfirm); + //Store data parameter + var template SCCP_PAR_UserData tl_data := omit; + if (ispresent(pl_PDU_SCCP_ConnectionConfirm.optionalPart)) + { + if (ispresent(pl_PDU_SCCP_ConnectionConfirm.optionalPart.data)) + { + tl_data := pl_PDU_SCCP_ConnectionConfirm.optionalPart.data.data; + } + } + //check if connection already established if (ConnectionAlreadyEstablished(pl_PDU_SCCP_ConnectionConfirm.destLocRef)) {//startif2 @@ -3808,7 +3818,7 @@ group SCCPFunctions SCCP_SP_PORT.send( t_ASP_N_CONNECT_cfm( omit, omit, - omit, + tl_data, vl_N_CONNECT_cfm.connectionId, omit ));//send ASP_SCCP_N_CONNECT_confirm