ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/socket/loop.C
(Generate patch)

Comparing deliantra/server/socket/loop.C (file contents):
Revision 1.89 by root, Sat Apr 23 04:56:58 2011 UTC vs.
Revision 1.90 by root, Sat Dec 31 06:18:02 2011 UTC

178 destroy (); 178 destroy ();
179 } 179 }
180 } 180 }
181#endif 181#endif
182 182
183 // limit budget surplus/deficit by one mss, add per-tick budget
183 rate_avail = min (max_rate + mss, rate_avail + max_rate); 184 rate_avail = min (rate_avail, mss) + max_rate;
184 185
185 int max_send = rate_avail; 186 int max_send = rate_avail;
186 187
187#if HAVE_TCP_INFO 188#if HAVE_TCP_INFO
188 // further restrict the available bandwidth by the excess bandwidth available 189 // further restrict the available bandwidth by the excess bandwidth available
189 max_send = min (max_send, (tcpi.tcpi_snd_cwnd - tcpi.tcpi_unacked + tcpi.tcpi_sacked) * mss); 190 min_it (max_send, (tcpi.tcpi_snd_cwnd - tcpi.tcpi_unacked + tcpi.tcpi_sacked) * mss);
190#endif 191#endif
191 192
192 // round to next-lowest mss 193 // round to next-lowest mss
193 max_send -= max_send % mss; 194 max_send -= max_send % mss;
194 195

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines