[asterisk-commits] mnicholson: branch 1.6.0 r240092 - in /branches/1.6.0: ./ main/udptl.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Thu Jan 14 10:19:44 CST 2010
Author: mnicholson
Date: Thu Jan 14 10:19:41 2010
New Revision: 240092
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=240092
Log:
Merged revisions 240078 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
........
r240078 | mnicholson | 2010-01-14 10:14:35 -0600 (Thu, 14 Jan 2010) | 9 lines
This change fixes a few bugs in the way the far max IFP was calculated that were introduced in r231692.
(closes issue #16497)
Reported by: globalnetinc
Patches:
udptl-max-ifp-fix1.diff uploaded by mnicholson (license 96)
Tested by: globalnetinc
........
Modified:
branches/1.6.0/ (props changed)
branches/1.6.0/main/udptl.c
Propchange: branches/1.6.0/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.
Modified: branches/1.6.0/main/udptl.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.6.0/main/udptl.c?view=diff&rev=240092&r1=240091&r2=240092
==============================================================================
--- branches/1.6.0/main/udptl.c (original)
+++ branches/1.6.0/main/udptl.c Thu Jan 14 10:19:41 2010
@@ -802,10 +802,17 @@
* zero in this loop; we'd rather send smaller IFPs (and thus reduce
* the image data transfer rate) than sacrifice redundancy completely
*/
- for ( ;
- (new_max < 80) && (udptl->error_correction_entries > 1);
- --udptl->error_correction_entries) {
+ for (;;) {
new_max = (udptl->far_max_datagram - 8) / (udptl->error_correction_entries + 1);
+
+ if ((new_max < 80) && (udptl->error_correction_entries > 1)) {
+ /* the max ifp is not large enough, subtract an
+ * error correction entry and calculate again
+ * */
+ --udptl->error_correction_entries;
+ } else {
+ break;
+ }
}
break;
case UDPTL_ERROR_CORRECTION_FEC:
More information about the asterisk-commits
mailing list