aboutsummaryrefslogtreecommitdiffstats
path: root/src/libmsc/mncc_call.c
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2019-10-05 05:15:25 +0200
committerNeels Hofmeyr <neels@hofmeyr.de>2019-11-01 17:35:17 +0100
commit84ce206ae3e36b7a8623c7fec32203a226812ad2 (patch)
treeb82eb115a9cf73036c5854deb9c6c4f34a1666e6 /src/libmsc/mncc_call.c
parent523b92f3aadb9a63e3048f8fee58d380ced7b7dc (diff)
use osmo_sockaddr_str_is_nonzero()
Also regard an RTP port as invalid if the IP address is 0.0.0.0. Achieve this by using osmo_sockaddr_str_is_nonzero() instead of osmo_sockaddr_str_is_set(). Depends: I73cbcab90cffcdc9a5f8d5281c57c1f87b2c3550 (libosmocore) Change-Id: I53ddb19a70fda3deb906464e1b89c12d9b4c7cbd
Diffstat (limited to 'src/libmsc/mncc_call.c')
-rw-r--r--src/libmsc/mncc_call.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libmsc/mncc_call.c b/src/libmsc/mncc_call.c
index 5ca91d022..34c729913 100644
--- a/src/libmsc/mncc_call.c
+++ b/src/libmsc/mncc_call.c
@@ -256,7 +256,7 @@ static bool mncc_call_rx_rtp_create(struct mncc_call *mncc_call)
return true;
}
- if (!osmo_sockaddr_str_is_set(&mncc_call->rtps->local)) {
+ if (!osmo_sockaddr_str_is_nonzero(&mncc_call->rtps->local)) {
LOG_MNCC_CALL(mncc_call, LOGL_DEBUG, "Got RTP_CREATE, but RTP stream has no local address\n");
return true;
}
@@ -294,7 +294,7 @@ uint32_t mgcp_codec_to_mncc_payload_msg_type(enum mgcp_codecs codec)
static bool mncc_call_tx_rtp_create(struct mncc_call *mncc_call)
{
- if (!mncc_call->rtps || !osmo_sockaddr_str_is_set(&mncc_call->rtps->local)) {
+ if (!mncc_call->rtps || !osmo_sockaddr_str_is_nonzero(&mncc_call->rtps->local)) {
mncc_call_error(mncc_call, "Cannot send RTP_CREATE, no local RTP address set up\n");
return false;
}