W3C home > Mailing lists > Public > www-lib@w3.org > April to June 1997

Re: event loop on Linux (was Re: Direct WAIS access support in libwww)

From: Eric Prud'hommeaux <eric@w3.org>
Date: Mon, 16 Jun 1997 17:01:48 -0400 (EDT)
To: Rick Kwan <kenobi@NetPhonic.COM>
cc: www-lib@w3.org, qinglong@yggdrasil.com
Message-ID: <Pine.SOL.3.91.970616165630.136A-100000@anansi>
On Mon, 16 Jun 1997, Rick Kwan wrote:

> qinglong@yggdrasil.com writes...
>  
> >    I've failed to utilize direct WAIS access support in libwww-5.0a
> >  (libwww-5.1* just don't work for me on Linux --- they fail in deadloop).
> 
> I don't know if this is the same thing or not...  In libwww-5.0a on
> Linux, HTEventrg_loop() used to die on me.  I traced this back to the
> select() timeout value on Linux being updated to the unused time.  Once
> I got passed that it worked.

This should be handled as the following code enforces that the timeout 
pointer is either NULL or points to an updated waittime structure.

-eric
------------------------------HTEvtLst.c-------------------------------
    do {
        wt = NULL;
	...
        if (timeout != 0) {
            waittime.tv_sec = timeout / MILLI_PER_SECOND;
            waittime.tv_usec = (timeout % MILLI_PER_SECOND) *
                (1000000 / MILLI_PER_SECOND);
            wt = &waittime;
        }
	...
        active_sockets = select(maxfds+1, &treadset, &twriteset, 
				&texceptset, wt);
	...
	} while (!HTEndLoop);
Received on Monday, 16 June 1997 17:02:52 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 23 April 2007 18:18:27 GMT