lwip-devel
[Top][All Lists]
Advanced

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

[lwip-devel] [patch #10013] tcp_in: Flag the pcb as closing if TCP_EVENT


From: Simon Goldschmidt
Subject: [lwip-devel] [patch #10013] tcp_in: Flag the pcb as closing if TCP_EVENT_CLOSED refused
Date: Thu, 4 Mar 2021 15:39:40 -0500 (EST)
User-agent: Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:86.0) Gecko/20100101 Firefox/86.0

Update of patch #10013 (project lwip):

                  Status:                    None => In Progress            
             Assigned to:                    None => goldsimon              

    _______________________________________________________

Follow-up Comment #1:

I'm glad you found this bug, but I'm not sure this is the correct fix. It
seems you're mixing directions here: receiving a FIN does not mean sending
one. But setting TF_CLOSEPEND essentially means "send a FIN next time you
check this pcb".

However, a FIN should only be sent if the application gracefully closes the
TCP connection. *If* you wanted to do something in the stack, a RST would be
better. But since we don't want to break anything here, why don't we reuse
"pcb->refused_data" for this? Using NULL here won't work, so we need a special
value for TCP_EVENT_CLOSED vs. TCP_EVENT_RECV, but I think that might work
better.

    _______________________________________________________

Reply to this item at:

  <https://savannah.nongnu.org/patch/?10013>

_______________________________________________
  Message sent via Savannah
  https://savannah.nongnu.org/




reply via email to

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