httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Llelan D." <NOS...@TheSnakePitDev.com>
Subject [users@httpd] Re: Browser access to Apache on W2k hangs.
Date Tue, 21 Oct 2003 11:04:25 GMT
Robert Andersson wrote:
> Which while() loop do you mean? There is while(!shutdown_in_progress) and
> while(1). If the former, are they not hiting the Sleep(0) or Sleep(100)? If
> I understand your description correctly, you do not ever get to the while(1)
> loop.

The AcceptEx() call is only in the while(!shutdown_in_progress) loop. The 
while(1) loop is after the AcceptEx() error handling if-blocks and implements 
the context overlapped event wait, which I stated no thread ever reaches.

> Does it go something like this:
> 1. Hits if(!context), gets context and continues
> 2. Hits if(context->accept_socket == INVALID_SOCKET), and gets one
> 3. AcceptEx() fails.
> 4. rv == APR_FROM_OS_ERROR(WSANOTSOCK) is true, so it
>    close the socket, and set it to INVALID_SOCKET, and continues
> 5. Goto 2

Bingo, except 5 goes back to the the top of the while loop, before 1, via the 
continue statement.

> That's pretty weird. It is probably not context->socket that is messed up,
> but nlsd (the listening socket). Take a look in the debugger what value they
> both have.

As I said, I compiled in some getsockopt() calls and found both sockets to be 
valid (SO_ERROR == 0) and the listener to be listening (SO_ACCEPTCONN == TRUE).

> I'm not sure it is appropriate to suggest, but you could perhaps write up a
> summary of your findings and post to the developer list. A Windows developer
> might be able to suggest what is causing this behaviour.

That's where I intend to go next, I just wanted to get a proper development 
environment for Apache up and running, and to see if anyone here had anything 
to add.

Thanks for your help Robert. In the past, those few folk who have run into 
this have apparently given up and gone to another machine, but I want to 
identify this and solve it once and for all. Stuff like this keeps me up at 
night, and I get cranky without a nap <grin>.

-- 
--------------------------------------------------------
The Snake Pit - Development   www.TheSnakePitDev.com
Curtis Clauson                LlelanD@TheSnakePitDev.com
Proprietor

"Any sufficiently over-complicated magic is indistinguishable from 
technology." -- Llelan D.



---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message