summaryrefslogtreecommitdiff
path: root/channels/chan_iax2.c
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2014-07-21 16:09:33 +0000
committerJoshua Colp <jcolp@digium.com>2014-07-21 16:09:33 +0000
commit41337750c385aacc7d20a49be0dc1dbd745b2b8a (patch)
tree6a87c855111caddf7173381b651717acf0b13b0c /channels/chan_iax2.c
parent7677d564e779bf95268fb7c8a5523a6514c21f69 (diff)
chan_iax2: Only send mini frames if the underlying format has not changed, not if it has.
ASTERISK-24072 #close Reported by: Matt Jordan git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@419093 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/chan_iax2.c')
-rw-r--r--channels/chan_iax2.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/channels/chan_iax2.c b/channels/chan_iax2.c
index be5b4c751..29db828ea 100644
--- a/channels/chan_iax2.c
+++ b/channels/chan_iax2.c
@@ -6533,7 +6533,8 @@ static int iax2_send(struct chan_iax2_pvt *pvt, struct ast_frame *f, unsigned in
/* High two bytes are the same on timestamp, or sending on a trunk */ &&
(f->frametype == AST_FRAME_VOICE)
/* is a voice frame */ &&
- (ast_format_cmp(f->subclass.format, ast_format_compatibility_bitfield2format(pvt->svoiceformat)))
+ (ast_format_cmp(f->subclass.format, ast_format_compatibility_bitfield2format(pvt->svoiceformat)) ==
+ AST_FORMAT_CMP_EQUAL)
/* is the same type */ ) {
/* Force immediate rather than delayed transmission */
now = 1;
@@ -6547,7 +6548,8 @@ static int iax2_send(struct chan_iax2_pvt *pvt, struct ast_frame *f, unsigned in
* Otherwise send a mini video frame
*/
if (((fts & 0xFFFF8000L) == (pvt->lastvsent & 0xFFFF8000L)) &&
- (ast_format_cmp(f->subclass.format, ast_format_compatibility_bitfield2format(pvt->svideoformat)))
+ (ast_format_cmp(f->subclass.format, ast_format_compatibility_bitfield2format(pvt->svideoformat)) ==
+ AST_FORMAT_CMP_EQUAL)
) {
now = 1;
sendmini = 1;