Anduin Withers wrote:
In looking at this code further, if the threadPool is empty when
entering this function, won't it endlessly loop because prt is never set
to anything other than null?
The idea is that a thread will return to the pool, which is often right.
However there is a somewhat longstanding issue where the thread pool is
exhausted and threads aren't being returned. I'm pretty sure this is caused
by the main event loop not running (and being able to notice that a socket
has closed in the select rather than an attempted read).
The problem is that you don't generally hit this bug unless you're playing
around.
Unfortunately I ran into this problem doing nothing out of the
ordinary. Would it be appropriate for the code, once it notices an
empty pool, to kick off an event of function that replenishes the pool
as MainServer does when it starts?
Kevin
_______________________________________________
mythtv-dev mailing list
[email protected]
http://mythtv.org/cgi-bin/mailman/listinfo/mythtv-dev