lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] [bug #27871] Calling tcp_abort() in recv callback can lead


From: Jeff Barber
Subject: [lwip-devel] [bug #27871] Calling tcp_abort() in recv callback can lead to accessing unallocated memory
Date: Fri, 30 Oct 2009 18:20:17 +0000
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.1.4) Gecko/20091016 Firefox/3.5.4 GTB5

Follow-up Comment #1, bug #27871 (project lwip):

Wouldn't it be better to simply deprecate use of tcp_abort from
applications?

If one considers the usual unix behavior as an analog: an application can't
abort a connection.  It simply closes the socket.  Once closed, the OS cleans
up, sending the FIN and so forth, and can choose to reset the connection if,
for example, it continues to get data destined for a socket that is no longer
open.

For lwip, if an application wishes to close a session, it should call
tcp_close and clear its send and recv callbacks.  It will not then get any
further callbacks and so, as far as it's concerned, the session is gone.  lwip
is then responsible for cleanup: FIN-sending and/or possibly RST, as
appropriate.


    _______________________________________________________

Reply to this item at:

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

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





reply via email to

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