[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bug in tcp.cc?
It shouldn't fail if you explicitly set it to 0, but it could fail if
you set it to an expression that evaluates to 0 (e.g. 1/3*3-1). But
it doesn't do much harm, does it? If overhead_ is a very small
positive number, the delsnd_timer_ will be rescheduled by an even
smaller value (half of it, on average). Besides, how are you
suggesting to fix it? If we use something like (overhead < EPSILON),
what EPSILON should we pick?
Yuri.
Jitendra Padhye <jitu@cs.umass.edu> writes:
> Hi,
>
> In tcp.cc: (ns version 2.1b2)
>
> =====
> if (overhead_ == 0 || force) {
> output(t_seqno_++, reason);
> npackets++;
> =====
>
> However, "overhead_" is of type "double", so the equality test
> may fail even if overhead is set to 0 ...
>
> - Jitu