Correction on the DEBUG code.

prioritization
Diva Canto 2009-10-05 21:02:10 -07:00
parent e36a54ee2a
commit 0c46df973a
1 changed files with 3 additions and 4 deletions

View File

@ -963,11 +963,10 @@ namespace OpenSim.Region.Framework.Scenes
while (!shuttingdown) while (!shuttingdown)
{ {
#if DEBUG #if DEBUG
int w = 0, io = 0, maxw=0, maxio=0; int w = 0, io = 0;
ThreadPool.GetAvailableThreads(out w, out io); ThreadPool.GetAvailableThreads(out w, out io);
ThreadPool.GetMaxThreads(out maxw, out maxio); if ((w < 10) || (io < 10))
if ((maxw - w < 10) || (maxio - io < 10)) m_log.DebugFormat("[WARNING]: ThreadPool reaching exhaustion. workers = {0}; io = {1}", w, io);
m_log.DebugFormat("[WARNING]: ThreadPool reaching exhaustion. workers = {0}({1}); io = {2}({3})", w, io, maxw, maxio);
#endif #endif
maintc = Environment.TickCount; maintc = Environment.TickCount;