lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] [task #6861] Pimp ip_frag.c


From: Jonathan Larmour
Subject: [lwip-devel] [task #6861] Pimp ip_frag.c
Date: Fri, 03 Aug 2007 15:41:11 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.12) Gecko/20070530 Fedora/1.5.0.12-1.fc5 Firefox/1.5.0.12

Follow-up Comment #23, task #6861 (project lwip):

Thanks Thomas.

A few comments:
- TABs seem to be messing up the indenting, at least for me.
- Almost all functions need to be static.
- There are still uses of the IP_HLEN constant, instead of IPH_LEN
- In ip_reass_tmr():
                } else if (r->timer == 0) {
can just be:
 } else {
surely?

- This check:
 if ((ip_reass_pbufcount + clen) > IP_REASS_MAX_PBUFS) {
is interesting, because it means we effectively cannot reassemble _anything_
any more, until a timer expires one of them. Perhaps instead it should it
should loop calling ip_reass_tmr() (to expire the oldest packets) until space
appears.
- I'm not convinced of the need for a doubly linked list.
- I feel that it would save something if the operation of validate_datagram
could be incorporated into chain_frag_into_datagram, rather than repeating the
work.



This seems like a whole lot of code that's going to be made compulsory for
reassembly. 


    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/task/?6861>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.nongnu.org/





reply via email to

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