[asterisk-dev] proposed change to main/http.c

Kevin P. Fleming kpfleming at digium.com
Fri Oct 6 13:49:50 MST 2006


----- Luigi Rizzo <rizzo at icir.org> wrote:
> indeed, i don't understand why there are calls cwto set non-blocking
> mode
> all over the place. I think many of these are useless if not wrong.

I can't comment on the others, that would take more time than I have to review the code right now. However, I did ask Mark about why the HTTP listener socket is non-blocking, and he said that he's been doing that for years because there is a known-issue with half-open TCP connections blocking the socket during accept() (or something like that) if the socket is in blocking mode.

The fix you've already put in (to revert to blocking mode once accept() has given us an fd to work with) is certainly the correct fix for http.c.

-- 
Kevin P. Fleming
Senior Software Engineer
Digium, Inc.



More information about the asterisk-dev mailing list