[asterisk-commits] file: trunk r424753 - in /trunk: ./ main/data.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Tue Oct 7 13:34:42 CDT 2014
Author: file
Date: Tue Oct 7 13:34:40 2014
New Revision: 424753
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=424753
Log:
data: Properly access formats in capabilities structure when adding codecs.
Formats within a capabilities structure are addressed starting at 0, not 1.
Assuming 1 causes it to exceed an array.
ASTERISK-24389 #close
Reported by: Kevin Harwell
........
Merged revisions 424752 from http://svn.asterisk.org/svn/asterisk/branches/13
Modified:
trunk/ (props changed)
trunk/main/data.c
Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-13-merged' - no diff available.
Modified: trunk/main/data.c
URL: http://svnview.digium.com/svn/asterisk/trunk/main/data.c?view=diff&rev=424753&r1=424752&r2=424753
==============================================================================
--- trunk/main/data.c (original)
+++ trunk/main/data.c Tue Oct 7 13:34:40 2014
@@ -3146,7 +3146,7 @@
}
count = ast_format_cap_count(cap);
- for (i = 1; i <= count; ++i) {
+ for (i = 0; i < count; ++i) {
struct ast_format *fmt;
fmt = ast_format_cap_get_format(cap, i);
More information about the asterisk-commits
mailing list