aboutsummaryrefslogtreecommitdiffstats
path: root/src/hnbgw_hnbap.c
diff options
context:
space:
mode:
authorDaniel Willmann <dwillmann@sysmocom.de>2015-12-17 17:56:56 +0100
committerDaniel Willmann <dwillmann@sysmocom.de>2015-12-17 17:56:56 +0100
commit59d17d8961df96ff7cb22338e2af314a83ba12ab (patch)
treee9dfba5f00c5e9489fb0a2fa9c7cd5ad5b769327 /src/hnbgw_hnbap.c
parent6637a289da9267c021497112d420ff0665507f50 (diff)
hnbap: Free ASN.1 components after they are no longer needed
Diffstat (limited to 'src/hnbgw_hnbap.c')
-rw-r--r--src/hnbgw_hnbap.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/hnbgw_hnbap.c b/src/hnbgw_hnbap.c
index 9378c7a..219169a 100644
--- a/src/hnbgw_hnbap.c
+++ b/src/hnbgw_hnbap.c
@@ -69,6 +69,8 @@ static int hnbgw_tx_hnb_register_acc(struct hnb_context *ctx)
&asn_DEF_HNBRegisterAccept,
&accept_out);
+ ASN_STRUCT_FREE_CONTENTS_ONLY(asn_DEF_HNBRegisterAccept, &accept_out);
+
return hnbgw_hnbap_tx(ctx, msg);
}
@@ -294,6 +296,8 @@ int hnbgw_hnbap_rx(struct hnb_context *hnb, struct msgb *msg)
rc = _hnbgw_hnbap_rx(hnb, pdu);
+ ASN_STRUCT_FREE_CONTENTS_ONLY(asn_DEF_HNBAP_PDU, pdu);
+
return rc;
}