Fix end condition in ast_rtp_lookup_mime_multiple2.
authorDavid M. Lee <dlee@digium.com>
Wed, 9 Jan 2013 20:30:33 +0000 (20:30 +0000)
committerDavid M. Lee <dlee@digium.com>
Wed, 9 Jan 2013 20:30:33 +0000 (20:30 +0000)
The erroneous end condition would never include the AST_RTP_CISCO_DTMF flag
in the debug output.

(closes issue ASTERISK-20772)
Reported by: Xavier Hienne
........

Merged revisions 378776 from http://svn.asterisk.org/svn/asterisk/branches/1.8
........

Merged revisions 378780 from http://svn.asterisk.org/svn/asterisk/branches/11

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@378783 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/rtp_engine.c

index 29c9286..7cbfba0 100644 (file)
@@ -849,7 +849,7 @@ char *ast_rtp_lookup_mime_multiple2(struct ast_str *buf, struct ast_format_cap *
        } else {
                int x;
                ast_str_append(&buf, 0, "0x%x (", (unsigned int) rtp_capability);
-               for (x = 1; x < AST_RTP_MAX; x <<= 1) {
+               for (x = 1; x <= AST_RTP_MAX; x <<= 1) {
                        if (rtp_capability & x) {
                                name = ast_rtp_lookup_mime_subtype2(asterisk_format, NULL, x, options);
                                ast_str_append(&buf, 0, "%s|", name);