mgcp: release no longer used endpoint identifiers

When an MGCP endpoint is deleted, we need to mark its endpoint
id as unused, so other calls can used it. This is currently not
happening. This patch fixes that.

Change-Id: I346affea940efb3a55e9b34c28a6cbe676d57d56
This commit is contained in:
Philipp Maier 2017-06-08 14:21:50 +02:00 committed by Neels Hofmeyr
parent d4195472f5
commit 00a0862e9c
1 changed files with 4 additions and 1 deletions

View File

@ -334,10 +334,13 @@ void msc_call_release(struct gsm_trans *trans)
struct gsm_subscriber_connection *conn = trans->conn;
struct mgcpgw_client *mgcp = conn->network->mgcpgw.client;
/* Send DLCX */
msg = mgcp_msg_dlcx(mgcp, conn->iu.mgcp_rtp_endpoint);
if (mgcpgw_client_tx(mgcp, msg, NULL, NULL))
LOGP(DMGCP, LOGL_ERROR,
"Failed to send DLCX message for %s\n",
vlr_subscr_name(trans->vsub));
/* Release endpoint id */
mgcpgw_client_release_endpoint(conn->iu.mgcp_rtp_endpoint, mgcp);
}