pespin has uploaded this change for review. (
https://gerrit.osmocom.org/c/libosmo-sigtran/+/40614?usp=email )
Change subject: Use xua_msg_free() everywhere to free xua_msg
......................................................................
Use xua_msg_free() everywhere to free xua_msg
Change-Id: I1d43478a5c430e92f1bd5a0b3d3606a39f378e44
---
M src/sccp_scoc_fsm.c
M tests/xua/xua_test.c
2 files changed, 4 insertions(+), 4 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/libosmo-sigtran refs/changes/14/40614/1
diff --git a/src/sccp_scoc_fsm.c b/src/sccp_scoc_fsm.c
index fa3019e..1833b89 100644
--- a/src/sccp_scoc_fsm.c
+++ b/src/sccp_scoc_fsm.c
@@ -409,7 +409,7 @@
/* Send N-DISCONNECT.ind to local user */
sccp_conn_scu_gen_encode_and_send(conn, event, xua,
OSMO_SCU_PRIM_N_DISCONNECT, PRIM_OP_INDICATION);
- talloc_free(xua);
+ xua_msg_free(xua);
/* Send RLSD to peer */
sccp_conn_xua_gen_relre_and_send(conn, SCCP_RELEASE_CAUSE_EXPIRATION_INACTIVE, NULL);
/* start release timer */
@@ -457,7 +457,7 @@
/* send N-DISCONNECT.ind to user */
sccp_conn_scu_gen_encode_and_send(conn, event, xua,
OSMO_SCU_PRIM_N_DISCONNECT, PRIM_OP_INDICATION);
- talloc_free(xua);
+ xua_msg_free(xua);
/* Send RLSD to SCRC */
sccp_conn_xua_gen_relre_and_send(conn, SCCP_RELEASE_CAUSE_INCONSISTENT_CONN_DATA,
NULL);
/* Start release timer */
diff --git a/tests/xua/xua_test.c b/tests/xua/xua_test.c
index e3d9ac5..0759ff7 100644
--- a/tests/xua/xua_test.c
+++ b/tests/xua/xua_test.c
@@ -601,8 +601,8 @@
OSMO_ASSERT(xua_msg_get_u32(nested, M3UA_IEI_LOC_RKEY_ID) == 1);
OSMO_ASSERT(xua_msg_get_u32(nested, M3UA_IEI_DEST_PC) == 23);
- talloc_free(nested);
- talloc_free(xua);
+ xua_msg_free(nested);
+ xua_msg_free(xua);
}
static void test_sccp_addr_cmp(void)
--
To view, visit
https://gerrit.osmocom.org/c/libosmo-sigtran/+/40614?usp=email
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: libosmo-sigtran
Gerrit-Branch: master
Gerrit-Change-Id: I1d43478a5c430e92f1bd5a0b3d3606a39f378e44
Gerrit-Change-Number: 40614
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>