[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [bug #43739] Accept not reporting errors about aborted conn
From: |
Joel Cunningham |
Subject: |
[lwip-devel] [bug #43739] Accept not reporting errors about aborted connections |
Date: |
Wed, 03 Dec 2014 15:46:10 +0000 |
User-agent: |
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:33.0) Gecko/20100101 Firefox/33.0 |
Follow-up Comment #2, bug #43739 (project lwip):
I would agree out-of-pcbs should be included in this failure (also
out-of-sockets). The accept() call in sockets.c will return ENFILE if out of
sockets.
>From the application point of view, if a pending connection can't be handed
off due to failure to allocate connection state (either socket, netconn, or
pcb) it would make sense to be consistent with error handling.
When I encountered this, I had no idea why the connection was being aborted on
the server. It took considerable debugging in api_lib.c, api_msg.c, and
tcp_in.c to pinpoint the failure. There are no LWIP_ASSERTs for this
failure.
After looking up the opengroup specification for accept(), that lead me to
consider this a bug. I would consider it low priority since it just makes
life easier for application developers.
I'm not sure how the backlog should play into this since a full backlog
usually doesn't result in a RST, but ignoring the SYN or ignoring resulting
ACK from listener's SYN+ACK. The Linux backlog behavior is an interesting
data point:
http://veithen.github.io/2014/01/01/how-tcp-backlog-works-in-linux.html
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/bugs/?43739>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/