neels has uploaded this change for review.

View Change

rtp_stream_commit: check missing MGW ep only when ready for RTP

Change-Id: I24a81a926b97c9f0fb31df782d1cf931eaff9db1
---
M src/libmsc/rtp_stream.c
1 file changed, 4 insertions(+), 4 deletions(-)

git pull ssh://gerrit.osmocom.org:29418/osmo-msc refs/changes/12/30112/1
diff --git a/src/libmsc/rtp_stream.c b/src/libmsc/rtp_stream.c
index 2902520..c86d0be 100644
--- a/src/libmsc/rtp_stream.c
+++ b/src/libmsc/rtp_stream.c
@@ -361,10 +361,6 @@
* least one of them has not yet been sent to the MGW in a previous CRCX or MDCX. */
int rtp_stream_commit(struct rtp_stream *rtps)
{
- if (!rtps->ci) {
- LOG_RTPS(rtps, LOGL_DEBUG, "Not committing: no MGW endpoint CI set up\n");
- return -1;
- }
if (!osmo_sockaddr_str_is_nonzero(&rtps->remote)) {
LOG_RTPS(rtps, LOGL_DEBUG, "Not committing: no remote RTP address known\n");
return -1;
@@ -377,6 +373,10 @@
LOG_RTPS(rtps, LOGL_DEBUG, "Not committing: both remote RTP address and codec already set up at MGW\n");
return 0;
}
+ if (!rtps->ci) {
+ LOG_RTPS(rtps, LOGL_DEBUG, "Not committing: no MGW endpoint CI set up\n");
+ return -1;
+ }

LOG_RTPS(rtps, LOGL_DEBUG, "Committing: Tx MDCX to update the MGW: updating%s%s%s\n",
rtps->remote_sent_to_mgw ? "" : " remote-RTP-IP-port",

To view, visit change 30112. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: osmo-msc
Gerrit-Branch: master
Gerrit-Change-Id: I24a81a926b97c9f0fb31df782d1cf931eaff9db1
Gerrit-Change-Number: 30112
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr@sysmocom.de>
Gerrit-MessageType: newchange