lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] [task #11493] PPP - lcp.c nak_buffer is too large


From: Ivan Delamer
Subject: [lwip-devel] [task #11493] PPP - lcp.c nak_buffer is too large
Date: Wed, 26 Oct 2011 21:48:18 +0000
User-agent: Mozilla/5.0 (Windows NT 6.1; rv:7.0.1) Gecko/20100101 Firefox/7.0.1

URL:
  <http://savannah.nongnu.org/task/?11493>

                 Summary: PPP - lcp.c  nak_buffer is too large
                 Project: lwIP - A Lightweight TCP/IP stack
            Submitted by: idelamer
            Submitted on: Wed 26 Oct 2011 03:48:18 PM MDT
                Category: Network drivers
         Should Start On: Wed 26 Oct 2011 12:00:00 AM MDT
   Should be Finished on: Fri 26 Oct 2012 12:00:00 AM MDT
                Priority: 5 - Normal
                  Status: None
                 Privacy: Public
        Percent Complete: 0%
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: 1.4.1
                  Effort: 0.00

    _______________________________________________________

Details:

I'll be working with PPP so I may be posting some patches or tasks. I won't
push any commits until I receive some feedback or get proficient enough in PPP
to do so.

Today: in LCP layer (lcp.c) there is a buffer for NAK messages (line 110):

/* @todo: do we really need such a large buffer? The typical 1500 bytes seem
too much. */
static u_char nak_buffer[PPP_MRU]; /* where we construct a nak packet */ 

I checked the code and the maximum number of bytes used is 8 (in line 1478)

I suggest changing this line to:

static u_char nak_buffer[8];

and we'll save 1492 bytes of ram.




    _______________________________________________________

Reply to this item at:

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

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




reply via email to

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