[Ns-developers] Possible bug

Tom Henderson tomh at tomh.org
Thu Aug 28 06:08:13 PDT 2008


Ali Hamidian wrote:
> Hi,
> 
> I think there is a bug in ns-2, which can be solved in aodv.cc. In 
> AODV::recv, generated packets add the size of an IP header: ch->size() 
> += IP_HDR_LEN. But if the generated packet is a TCP segment, the IP 
> header has already been added in tcp.cc (tcpip_base_hdr_size_ = 40). So 
> the bug will result in TCP packets being 20 B larger than they should 
> be, i.e., first TCP will add 40 B for TCP and IP headers, and then AODV 
> will add 20 B for IP header. Moreover, I remember from the past that 
> this bug gives an error message when tcp-full.cc is used (e.g., by 
> webcache). To solve this in an easy way, in aodv.cc we should add the IP 
> header only if the packet is not PT_TCP or PT_ACK. See the attached file.
> 
> Kind regards,
> Ali
> 
> 

Ali,
I added it to the tracker.  If there are no other comments, I'll apply 
it before the next release.

Tom


More information about the Ns-developers mailing list