aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Couzens <lynxis@fe80.eu>2019-08-13 17:14:31 +0200
committerAlexander Couzens <lynxis@fe80.eu>2019-09-03 18:40:57 +0200
commit4ae261b89bb05139d72bd7458aa79579a56580cd (patch)
treeef438225f8b23e4416fc8d00a911110dd2f0c1a9
parent87482b335c79643f2908406f1fe29af4b759e595 (diff)
iu_client: sccp_sap_up: don't decode empty disconnect indications
-rw-r--r--src/iu_client.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/iu_client.c b/src/iu_client.c
index 8da9a43..ce06f8a 100644
--- a/src/iu_client.c
+++ b/src/iu_client.c
@@ -799,7 +799,9 @@ static int sccp_sap_up(struct osmo_prim_hdr *oph, void *_scu)
if (!ue)
break;
- rc = ranap_cn_rx_co(cn_ranap_handle_co, ue, msgb_l2(oph->msg), msgb_l2len(oph->msg));
+ rc = 0;
+ if (msgb_l2len(oph->msg) > 0)
+ rc = ranap_cn_rx_co(cn_ranap_handle_co, ue, msgb_l2(oph->msg), msgb_l2len(oph->msg));
break;
case OSMO_PRIM(OSMO_SCU_PRIM_N_DATA, PRIM_OP_INDICATION):
/* connection-oriented data received */