Change in osmo-mgw[master]: mgcp_client_fsm cleanup: Do not assert on DLCX failure

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/.

laforge gerrit-no-reply at lists.osmocom.org
Mon Oct 28 19:31:58 UTC 2019


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

Change subject: mgcp_client_fsm cleanup: Do not assert on DLCX failure
......................................................................

mgcp_client_fsm cleanup: Do not assert on DLCX failure

During FSM instance cleanup, a DLCX message composition may fail if a preceding
received MGCP message was missing parameters. If that occurs, don't crash, just
log an error and deallocate.

Change-Id: Ic1c3c4deeb4703b60e870af9d5d7be216a87fff8
---
M src/libosmo-mgcp-client/mgcp_client_fsm.c
1 file changed, 4 insertions(+), 2 deletions(-)

Approvals:
  Jenkins Builder: Verified
  pespin: Looks good to me, but someone else must approve
  laforge: 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 e83a119..7565d32 100644
--- a/src/libosmo-mgcp-client/mgcp_client_fsm.c
+++ b/src/libosmo-mgcp-client/mgcp_client_fsm.c
@@ -525,8 +525,10 @@
 		LOGPFSML(fi, LOGL_ERROR,
 			 "MGW/DLCX: abrupt FSM termination with connections still present, sending unconditional DLCX...\n");
 		msg = make_dlcx_msg(mgcp_ctx);
-		OSMO_ASSERT(msg);
-		mgcp_client_tx(mgcp, msg, NULL, NULL);
+		if (!msg)
+			LOGPFSML(fi, LOGL_ERROR, "MGW/DLCX: Error composing DLCX message\n");
+		else
+			mgcp_client_tx(mgcp, msg, NULL, NULL);
 	}
 
 	talloc_free(mgcp_ctx);

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

Gerrit-Project: osmo-mgw
Gerrit-Branch: master
Gerrit-Change-Id: Ic1c3c4deeb4703b60e870af9d5d7be216a87fff8
Gerrit-Change-Number: 15836
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge at osmocom.org>
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/20191028/24142042/attachment.htm>


More information about the gerrit-log mailing list