[svn-commits] wdoekes: branch 11 r413791 - /branches/11/res/res_format_attr_h264.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue May 13 08:50:17 CDT 2014


Author: wdoekes
Date: Tue May 13 08:50:10 2014
New Revision: 413791

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=413791
Log:
h264: Fix H264 SDP payload format.

https://tools.ietf.org/html/rfc3984#section-8.1 says profile-level-id
takes 3 bytes in base16 (6 hex digits).

This fixes video setup in certain cases.

ASTERISK-23664 #close
ASTERISK-23664 #comment Patch r3530.patch uploaded by Guillaume Maudoux.
Review: https://reviewboard.asterisk.org/r/3530/

Modified:
    branches/11/res/res_format_attr_h264.c

Modified: branches/11/res/res_format_attr_h264.c
URL: http://svnview.digium.com/svn/asterisk/branches/11/res/res_format_attr_h264.c?view=diff&rev=413791&r1=413790&r2=413791
==============================================================================
--- branches/11/res/res_format_attr_h264.c (original)
+++ branches/11/res/res_format_attr_h264.c Tue May 13 08:50:10 2014
@@ -268,11 +268,11 @@
 		} else if (i == H264_ATTR_KEY_PROFILE_IDC && format_attr->format_attr[H264_ATTR_KEY_PROFILE_IDC] &&
 		    format_attr->format_attr[H264_ATTR_KEY_PROFILE_IOP] && format_attr->format_attr[H264_ATTR_KEY_LEVEL]) {
 			if (!added) {
-				ast_str_append(str, 0, "a=fmtp:%u profile-level-id=%X%X%X", payload, format_attr->format_attr[H264_ATTR_KEY_PROFILE_IDC],
+				ast_str_append(str, 0, "a=fmtp:%u profile-level-id=%02X%02X%02X", payload, format_attr->format_attr[H264_ATTR_KEY_PROFILE_IDC],
 					       format_attr->format_attr[H264_ATTR_KEY_PROFILE_IOP], format_attr->format_attr[H264_ATTR_KEY_LEVEL]);
 				added = 1;
 			} else {
-				ast_str_append(str, 0, ";profile-level-id=%X%X%X", format_attr->format_attr[H264_ATTR_KEY_PROFILE_IDC],
+				ast_str_append(str, 0, ";profile-level-id=%02X%02X%02X", format_attr->format_attr[H264_ATTR_KEY_PROFILE_IDC],
 					       format_attr->format_attr[H264_ATTR_KEY_PROFILE_IOP], format_attr->format_attr[H264_ATTR_KEY_LEVEL]);
 			}
 		} else if ((name = h264_attr_key_to_str(i)) && h264_attr_key_addable(format_attr, i)) {




More information about the svn-commits mailing list