Change in osmo-mgw[master]: mgcp_client_fsm delete: set mgcp_client as ctx, not NULL

laforge gerrit-no-reply at lists.osmocom.org
Fri Jul 16 15:58:16 UTC 2021


laforge has submitted this change. ( https://gerrit.osmocom.org/c/osmo-mgw/+/24946 )

Change subject: mgcp_client_fsm delete: set mgcp_client as ctx, not NULL
......................................................................

mgcp_client_fsm delete: set mgcp_client as ctx, not NULL

Upon mgcp_conn_delete(), we unparent the FSM instance. Instead of
setting the talloc ctx to NULL, place the deleting conn under the
struct mgcp_client talloc ctx.

Related: SYS#5529
Change-Id: Ia12749e0d7d520f24a967c2df9a4651267e1019e
---
M src/libosmo-mgcp-client/mgcp_client_fsm.c
1 file changed, 2 insertions(+), 2 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, but someone else must approve
  dexter: Looks good to me, but someone else must approve
  neels: Looks good to me, approved



diff --git a/src/libosmo-mgcp-client/mgcp_client_fsm.c b/src/libosmo-mgcp-client/mgcp_client_fsm.c
index 1c0cd59..57c6d98 100644
--- a/src/libosmo-mgcp-client/mgcp_client_fsm.c
+++ b/src/libosmo-mgcp-client/mgcp_client_fsm.c
@@ -709,8 +709,8 @@
 	if (fi->proc.terminating)
 		return;
 
-	/* Unlink FSM from parent */
-	osmo_fsm_inst_unlink_parent(fi, NULL);
+	/* Unlink FSM from parent, set the struct mgcp_client as new talloc ctx. */
+	osmo_fsm_inst_unlink_parent(fi, mgcp_ctx->mgcp);
 
 	/* An error situation where the parent FSM must be killed immediately
 	 * may lead into a situation where the DLCX can not be executed right

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-mgw/+/24946
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-mgw
Gerrit-Branch: master
Gerrit-Change-Id: Ia12749e0d7d520f24a967c2df9a4651267e1019e
Gerrit-Change-Number: 24946
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier at sysmocom.de>
Gerrit-Reviewer: laforge <laforge at osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210716/0fb96200/attachment.htm>


More information about the gerrit-log mailing list