diff options
author | Neels Hofmeyr <neels@hofmeyr.de> | 2019-10-05 05:15:25 +0200 |
---|---|---|
committer | Neels Hofmeyr <neels@hofmeyr.de> | 2019-11-01 17:35:17 +0100 |
commit | 84ce206ae3e36b7a8623c7fec32203a226812ad2 (patch) | |
tree | b82eb115a9cf73036c5854deb9c6c4f34a1666e6 /src/libmsc/msc_ho.c | |
parent | 523b92f3aadb9a63e3048f8fee58d380ced7b7dc (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/msc_ho.c')
-rw-r--r-- | src/libmsc/msc_ho.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libmsc/msc_ho.c b/src/libmsc/msc_ho.c index 615b8cd70..99f37b645 100644 --- a/src/libmsc/msc_ho.c +++ b/src/libmsc/msc_ho.c @@ -661,7 +661,7 @@ static void msc_ho_rx_request_ack(struct msc_a *msc_a, struct msc_a_ran_dec_data } msc_a->ho.new_cell.ran_remote_rtp = hra->ran_dec->handover_request_ack.remote_rtp; - if (osmo_sockaddr_str_is_set(&msc_a->ho.new_cell.ran_remote_rtp)) { + if (osmo_sockaddr_str_is_nonzero(&msc_a->ho.new_cell.ran_remote_rtp)) { LOG_HO(msc_a, LOGL_DEBUG, "Request Ack contains cell's RTP address " OSMO_SOCKADDR_STR_FMT "\n", OSMO_SOCKADDR_STR_FMT_ARGS(&msc_a->ho.new_cell.ran_remote_rtp)); } @@ -684,7 +684,7 @@ static void msc_ho_rtp_switch_to_new_cell(struct msc_a *msc_a) return; } - if (!osmo_sockaddr_str_is_set(&msc_a->ho.new_cell.ran_remote_rtp)) { + if (!osmo_sockaddr_str_is_nonzero(&msc_a->ho.new_cell.ran_remote_rtp)) { LOG_HO(msc_a, LOGL_DEBUG, "New cell's RTP IP:port not yet known, not switching RTP stream\n"); return; } @@ -738,7 +738,7 @@ static void msc_ho_rtp_rollback_to_old_cell(struct msc_a *msc_a) return; } - if (!osmo_sockaddr_str_is_set(&msc_a->ho.old_cell.ran_remote_rtp)) { + if (!osmo_sockaddr_str_is_nonzero(&msc_a->ho.old_cell.ran_remote_rtp)) { LOG_HO(msc_a, LOGL_DEBUG, "Have no RTP IP:port for the old cell, not switching back to\n"); return; } |