More problems with timeouts

I am running version 5.2.8 on a Win32 platform (i.e. WWW_WIN_ASYNC is
turned on).  I was having some trouble in the past with doing a simple
non-preemptive webget and having libwww hang in HTEventList_loop.  I was
told there were some fixes in htevtlst.c that were relevant to my problem
since the last release.  So I upgraded htevtlst.c from version 2.38 to
version 2.41, and my problem seemed to go away.

Now I'm having another problem with this function never returning.  When I
am on a dialup connection and do a successful non-preemptive webget, and
then disconnect, the next attempt at a webget hangs in HTEventList_loop.
So I looked a bit into the code and here is what I found.

In the function EventListTimerHandler, the code only checks on timeouts
related to READs, WRITEs, or OOBs.  I presume this is because in the UNIX
version of the event handler, these are the only "real" types.  This is
according to a comment in htevent.h.  However, if I put a break in this
code, my timeout triggers a timeout for HTEvent_CLOSE, and if I add this
handler to EventListTimerHandler, my timeout is successfully triggered and
HTEventList_loop returns with a HT_TIMEOUT indication.

Questions: I need to try and understand why I can't seem to rely on whether
or not HTEventList_loop will ever return.  Who wrote the WWW_WIN_ASYNC
version of the event loop, and/or who understands this code enough to
enlighten me?  Functions in libwww that never return are not conducive to
my application behaving very well. :)

Thanks in advance,
Joel


-----------------------
Joel DeYoung
Maple Ridge, BC, Canada
joel@deyoung.net
http://joel.deyoung.net

Received on Thursday, 20 April 2000 12:08:59 UTC