aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
authorfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2008-12-18 17:11:42 +0000
committerfile <file@f38db490-d61c-443f-a65b-d21fe96a405b>2008-12-18 17:11:42 +0000
commitf65397c391faf06e18ca260a9549fffec533ce66 (patch)
tree16fa2dec49bf41a2a707dece32a4aa8f38db0005 /main
parentbff3891bdeefffd2b37ed5fa38c4bdaddd92b58a (diff)
Only care about a compatible codec for early bridging if we are actually bridging to another channel. If we are not we actually want to bring the audio back to us.
(closes issue #13545) Reported by: davidw git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@165591 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'main')
-rw-r--r--main/rtp.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/main/rtp.c b/main/rtp.c
index 01083410d..28fcad75f 100644
--- a/main/rtp.c
+++ b/main/rtp.c
@@ -1540,10 +1540,9 @@ int ast_rtp_early_bridge(struct ast_channel *dest, struct ast_channel *src)
else
destcodec = 0;
/* Ensure we have at least one matching codec */
- if (!(srccodec & destcodec)) {
+ if (srcp && !(srccodec & destcodec)) {
ast_channel_unlock(dest);
- if (src)
- ast_channel_unlock(src);
+ ast_channel_unlock(src);
return 0;
}
/* Consider empty media as non-existant */