Avoid using the name "early media" for media that is not early
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@33108 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
parent
7b2bd1a069
commit
e466f202b3
11
rtp.c
11
rtp.c
|
@ -1221,6 +1221,7 @@ int ast_rtp_early_media(struct ast_channel *dest, struct ast_channel *src)
|
||||||
struct ast_rtp *vdestp, *vsrcp=NULL; /* Video RTP channels */
|
struct ast_rtp *vdestp, *vsrcp=NULL; /* Video RTP channels */
|
||||||
struct ast_rtp_protocol *destpr, *srcpr=NULL;
|
struct ast_rtp_protocol *destpr, *srcpr=NULL;
|
||||||
int srccodec;
|
int srccodec;
|
||||||
|
|
||||||
/* Lock channels */
|
/* Lock channels */
|
||||||
ast_channel_lock(dest);
|
ast_channel_lock(dest);
|
||||||
if (src) {
|
if (src) {
|
||||||
|
@ -1275,14 +1276,14 @@ int ast_rtp_early_media(struct ast_channel *dest, struct ast_channel *src)
|
||||||
/* Consider empty media as non-existant */
|
/* Consider empty media as non-existant */
|
||||||
if (srcp && !srcp->them.sin_addr.s_addr)
|
if (srcp && !srcp->them.sin_addr.s_addr)
|
||||||
srcp = NULL;
|
srcp = NULL;
|
||||||
/* Bridge early media */
|
/* Bridge media early */
|
||||||
if (destpr->set_rtp_peer(dest, srcp, vsrcp, srccodec, srcp ? ast_test_flag(srcp, FLAG_NAT_ACTIVE) : 0))
|
if (destpr->set_rtp_peer(dest, srcp, vsrcp, srccodec, srcp ? ast_test_flag(srcp, FLAG_NAT_ACTIVE) : 0))
|
||||||
ast_log(LOG_WARNING, "Channel '%s' failed to send early media to '%s'\n", dest->name, src ? src->name : "<unspecified>");
|
ast_log(LOG_WARNING, "Channel '%s' failed to setup early bridge to '%s'\n", dest->name, src ? src->name : "<unspecified>");
|
||||||
ast_channel_unlock(dest);
|
ast_channel_unlock(dest);
|
||||||
if (src)
|
if (src)
|
||||||
ast_channel_unlock(src);
|
ast_channel_unlock(src);
|
||||||
if (option_debug)
|
if (option_debug)
|
||||||
ast_log(LOG_DEBUG, "Setting early media SDP of '%s' with that of '%s'\n", dest->name, src ? src->name : "<unspecified>");
|
ast_log(LOG_DEBUG, "Setting early bridge SDP of '%s' with that of '%s'\n", dest->name, src ? src->name : "<unspecified>");
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1339,9 +1340,9 @@ int ast_rtp_make_compatible(struct ast_channel *dest, struct ast_channel *src, i
|
||||||
else
|
else
|
||||||
srccodec = 0;
|
srccodec = 0;
|
||||||
if (media) {
|
if (media) {
|
||||||
/* Bridge early media */
|
/* Bridge early */
|
||||||
if (destpr->set_rtp_peer(dest, srcp, vsrcp, srccodec, ast_test_flag(srcp, FLAG_NAT_ACTIVE)))
|
if (destpr->set_rtp_peer(dest, srcp, vsrcp, srccodec, ast_test_flag(srcp, FLAG_NAT_ACTIVE)))
|
||||||
ast_log(LOG_WARNING, "Channel '%s' failed to send early media to '%s'\n", dest->name, src->name);
|
ast_log(LOG_WARNING, "Channel '%s' failed to setup early bridge to '%s'\n", dest->name, src->name);
|
||||||
}
|
}
|
||||||
ast_channel_unlock(dest);
|
ast_channel_unlock(dest);
|
||||||
ast_channel_unlock(src);
|
ast_channel_unlock(src);
|
||||||
|
|
Loading…
Reference in New Issue