>From a reading of the explanatory comment at the beginning of
queue_ready_ports()...
/*
* Call select() on the pending ports and move any ready ones to the ready
* queue. If wait is true, seconds is either -1 (wait forever) or the
* maximum number of seconds to wait (with ticks any additional ticks).
* The returned value is a status code.
*/
if there are no ready ports, then the function moves no pending ports
to the queue. So the initial test
if ((! wait)
&& (pending.first == NULL))
return (NO_ERRORS);
is too narrow. We should exit with NO_ERRORS whenever there are no
pending ports, no matter the value 'wait'. This is the same effective
behavior as a select() call that finds no ready ports. The
replacement code should be
if (pending.first == NULL)
return (NO_ERRORS);
I'm running a custom build with that patch to look for any weird
impact, and it has been looking good so far.
Derek
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]