lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] [bug #47260] Implementation bugs in LWIP_FIONREAD_LINUXMODE


From: Joel Cunningham
Subject: [lwip-devel] [bug #47260] Implementation bugs in LWIP_FIONREAD_LINUXMODE for UDP
Date: Thu, 25 Feb 2016 19:00:56 +0000
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:44.0) Gecko/20100101 Firefox/44.0

URL:
  <http://savannah.nongnu.org/bugs/?47260>

                 Summary: Implementation bugs in LWIP_FIONREAD_LINUXMODE for
UDP
                 Project: lwIP - A Lightweight TCP/IP stack
            Submitted by: jcunningham
            Submitted on: Thu 25 Feb 2016 07:00:55 PM GMT
                Category: sockets/netconn
                Severity: 3 - Normal
              Item Group: Faulty Behaviour
                  Status: None
                 Privacy: Public
             Assigned to: None
             Open/Closed: Open
         Discussion Lock: Any
         Planned Release: 
            lwIP version: git head

    _______________________________________________________

Details:

The UDP support with LWIP_FIONREAD_LINUXMODE set to 1 has a couple of bugs in
the implementation:

1) if sock->lastdata is not NULL, the output pointer of FIONREAD is not set
2) argp is being cast to u16_t * even though the other FIONREAD code uses a
int.  Linux code uses an int
3) sock->lastoffset was not set even though we are setting sock->lastdata. 
This could cause a problem on the next recv() call

1) was discovered when calling ioctl() twice in a row without a recv() in
between

The attached patch fixes these issues



    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Thu 25 Feb 2016 07:00:55 PM GMT  Name:
0001-Fix-bug-in-FIONREAD-handling-in-LINUXMODE.patch  Size: 1kB   By:
jcunningham

<http://savannah.nongnu.org/bugs/download.php?file_id=36459>

    _______________________________________________________

Reply to this item at:

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

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




reply via email to

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