This is merely a historical archive of years 2008-2021, before the migration to mailman3.
A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.
Harald Welte gerrit-no-reply at lists.osmocom.orgHarald Welte has submitted this change and it was merged. ( https://gerrit.osmocom.org/8065 )
Change subject: free msgb for primitive allocated in lm_timer_cb() of lm_fsm
......................................................................
free msgb for primitive allocated in lm_timer_cb() of lm_fsm
A primitive allocated in lm_timer_cb() with xua_xlm_prim_alloc()
was never freed. Don't forget to free the msgb in osmo_xlm_sap_down().
Found by code inspection.
Also, assert that allocation suceeded like we do elsewhere.
Change-Id: Ie667b1b8beeda2aa4520a1413f51101435215cc0
Related: OS#2449
---
M src/xua_default_lm_fsm.c
M src/xua_rkm.c
2 files changed, 2 insertions(+), 0 deletions(-)
Approvals:
Jenkins Builder: Verified
Harald Welte: Looks good to me, approved
diff --git a/src/xua_default_lm_fsm.c b/src/xua_default_lm_fsm.c
index eba89c2..11a97a2 100644
--- a/src/xua_default_lm_fsm.c
+++ b/src/xua_default_lm_fsm.c
@@ -175,6 +175,7 @@
* let's dynamically register */
osmo_fsm_inst_state_chg(fi, S_RKM_REG, 10, T_WAIT_RK_REG_RESP);
prim = xua_xlm_prim_alloc(OSMO_XLM_PRIM_M_RK_REG, PRIM_OP_REQUEST);
+ OSMO_ASSERT(prim);
as = find_first_as_in_asp(lmp->asp);
if (!as) {
LOGPFSML(fi, LOGL_ERROR, "Unable to find AS!\n");
diff --git a/src/xua_rkm.c b/src/xua_rkm.c
index b3c5be7..b79f7f3 100644
--- a/src/xua_rkm.c
+++ b/src/xua_rkm.c
@@ -545,6 +545,7 @@
break;
}
+ msgb_free(prim->oph.msg);
return 0;
}
--
To view, visit https://gerrit.osmocom.org/8065
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: libosmo-sccp
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: Ie667b1b8beeda2aa4520a1413f51101435215cc0
Gerrit-Change-Number: 8065
Gerrit-PatchSet: 2
Gerrit-Owner: Stefan Sperling <ssperling at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20180515/c026bac4/attachment.htm>