mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-11 20:38:45 +00:00
Merge "res_rtp_asterisk.c: Initialize ourip passed to ast_find_ourip()." into 13
This commit is contained in:
@@ -4915,9 +4915,11 @@ static void ast_rtp_prop_set(struct ast_rtp_instance *instance, enum ast_rtp_pro
|
|||||||
ast_sockaddr_set_port(&rtp->rtcp->us,
|
ast_sockaddr_set_port(&rtp->rtcp->us,
|
||||||
ast_sockaddr_port(&rtp->rtcp->us) + 1);
|
ast_sockaddr_port(&rtp->rtcp->us) + 1);
|
||||||
|
|
||||||
|
ast_sockaddr_copy(&local_addr, &rtp->rtcp->us);
|
||||||
if (!ast_find_ourip(&local_addr, &rtp->rtcp->us, 0)) {
|
if (!ast_find_ourip(&local_addr, &rtp->rtcp->us, 0)) {
|
||||||
ast_sockaddr_set_port(&local_addr, ast_sockaddr_port(&rtp->rtcp->us));
|
ast_sockaddr_set_port(&local_addr, ast_sockaddr_port(&rtp->rtcp->us));
|
||||||
} else {
|
} else {
|
||||||
|
/* Failed to get local address reset to use default. */
|
||||||
ast_sockaddr_copy(&local_addr, &rtp->rtcp->us);
|
ast_sockaddr_copy(&local_addr, &rtp->rtcp->us);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user