lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] [bug #21107] LwIP doesn't reset the TTL in ICMP Echo Replie


From: Frédéric Bernon
Subject: [lwip-devel] [bug #21107] LwIP doesn't reset the TTL in ICMP Echo Replies
Date: Tue, 18 Sep 2007 10:02:42 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr; rv:1.8.1.6) Gecko/20070725 Firefox/2.0.0.6

Follow-up Comment #7, bug #21107 (project lwip):

>The icmp echo change is already done, so in addition to your suggested
patch, we simply have to substract the old ttl and add the new ttl to the
checksum and that should be it.

I'm agree, I just do this remark because it give a code less readable than
calling :

IPH_CHKSUM_SET(iphdr, 0);
#if CHECKSUM_GEN_IP
    IPH_CHKSUM_SET(iphdr, inet_chksum(iphdr, IP_HLEN));
#endif

Ok, it's slower (except if your MAC do any offload computing), but I don't
think that any device receive "lot" of ICMP echos.

That's why readability & footprint (yes, a very little bit) could be choosen
here. But it's just a remark of course, so feel free to change it...




    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/bugs/?21107>

_______________________________________________
  Message posté via/par Savannah
  http://savannah.nongnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]