dexter has uploaded this change for review. (
https://gerrit.osmocom.org/c/osmo-iuh/+/27136 )
Change subject: ranap_common: add decoder for RAB-FailedList
......................................................................
ranap_common: add decoder for RAB-FailedList
There is currently no decoder to decode RAB-FailedList objects properly.
Lets add one.
Change-Id: I0f42487968f2a39f2425068c001950509a3bd28f
Related: OS#5152
---
M include/osmocom/ranap/ranap_common.h
M src/ranap_common.c
2 files changed, 29 insertions(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-iuh refs/changes/36/27136/1
diff --git a/include/osmocom/ranap/ranap_common.h b/include/osmocom/ranap/ranap_common.h
index 7511a75..50d15ed 100644
--- a/include/osmocom/ranap/ranap_common.h
+++ b/include/osmocom/ranap/ranap_common.h
@@ -648,6 +648,11 @@
ANY_t *any_p);
/* There is no generated decoder available, this is a custom one */
+int ranap_decode_rab_faileditemies_fromlist(
+ RANAP_RAB_FailedItemIEs_t *raB_FailedItemIEs,
+ ANY_t *any_p);
+
+/* There is no generated decoder available, this is a custom one */
int ranap_decode_rab_setupormodifyitemfirst(
RANAP_RAB_SetupOrModifyItemFirst_t *raB_SetupOrModifyItemFirst,
ANY_t *any_p);
diff --git a/src/ranap_common.c b/src/ranap_common.c
index 6c6d97c..dc55988 100644
--- a/src/ranap_common.c
+++ b/src/ranap_common.c
@@ -582,6 +582,30 @@
return decoded;
}
+int ranap_decode_rab_faileditemies_fromlist(RANAP_RAB_FailedItemIEs_t *raB_FailedItemIEs,
ANY_t *any_p)
+{
+
+ RANAP_RAB_FailedItem_t *ranaP_RABFailedItem_p = NULL;
+ int decoded;
+
+ assert(any_p != NULL);
+ assert(raB_FailedItemIEs != NULL);
+
+ memset(raB_FailedItemIEs, 0, sizeof(RANAP_RAB_FailedItemIEs_t));
+ RANAP_DEBUG("Decoding message RANAP_RAB_FailedItemIEs (%s:%d)\n", __FILE__,
__LINE__);
+ decoded = ANY_to_type_aper(any_p, &asn_DEF_RANAP_RAB_FailedItem, (void
**)&ranaP_RABFailedItem_p);
+ if (decoded < 0) {
+ RANAP_DEBUG("Decoding of IE raB_FailedItem failed\n");
+ return -1;
+ }
+ if (asn1_xer_print)
+ xer_fprint(stdout, &asn_DEF_RANAP_RAB_FailedItem, ranaP_RABFailedItem_p);
+ memcpy(&raB_FailedItemIEs->raB_FailedItem, ranaP_RABFailedItem_p,
sizeof(RANAP_RAB_FailedItem_t));
+ FREEMEM(ranaP_RABFailedItem_p);
+
+ return decoded;
+}
+
int ranap_decode_rab_setupormodifyitemfirst(
RANAP_RAB_SetupOrModifyItemFirst_t *raB_SetupOrModifyItemFirst,
ANY_t *any_p)
--
To view, visit
https://gerrit.osmocom.org/c/osmo-iuh/+/27136
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-iuh
Gerrit-Branch: master
Gerrit-Change-Id: I0f42487968f2a39f2425068c001950509a3bd28f
Gerrit-Change-Number: 27136
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-MessageType: newchange