You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by tr...@apache.org on 2005/10/31 11:27:02 UTC

svn commit: r329793 - /directory/network/branches/0.8/src/java/org/apache/mina/util/BaseThreadPool.java

Author: trustin
Date: Mon Oct 31 02:26:58 2005
New Revision: 329793

URL: http://svn.apache.org/viewcvs?rev=329793&view=rev
Log:
Fixed: another lockup in ThreadPoolFilter.

Modified:
    directory/network/branches/0.8/src/java/org/apache/mina/util/BaseThreadPool.java

Modified: directory/network/branches/0.8/src/java/org/apache/mina/util/BaseThreadPool.java
URL: http://svn.apache.org/viewcvs/directory/network/branches/0.8/src/java/org/apache/mina/util/BaseThreadPool.java?rev=329793&r1=329792&r2=329793&view=diff
==============================================================================
--- directory/network/branches/0.8/src/java/org/apache/mina/util/BaseThreadPool.java (original)
+++ directory/network/branches/0.8/src/java/org/apache/mina/util/BaseThreadPool.java Mon Oct 31 02:26:58 2005
@@ -182,7 +182,10 @@
                 leader.interrupt();
                 try
                 {
-                    leader.join();
+                    // This timeout (100) will help us from 
+                    // infinite lock-up and interrupt workers again.
+                    // (Or we could acquire a monitor for unfetchedSessionBuffers.)
+                    leader.join( 100 );
                 }
                 catch( InterruptedException e )
                 {
@@ -368,11 +371,6 @@
             {
                 for( ;; )
                 {
-                    if( shuttingDown )
-                    {
-                        return null;
-                    }
-
                     try
                     {
                         unfetchedSessionBuffers.waitForNewItem();