start to add back in features
authorfhanik <fhanik@13f79535-47bb-0310-9956-ffa450edef68>
Mon, 24 Nov 2008 22:39:48 +0000 (22:39 +0000)
committerfhanik <fhanik@13f79535-47bb-0310-9956-ffa450edef68>
Mon, 24 Nov 2008 22:39:48 +0000 (22:39 +0000)
git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@720317 13f79535-47bb-0310-9956-ffa450edef68

modules/jdbc-pool/java/org/apache/tomcat/jdbc/pool/FairBlockingQueue.java

index c25e207..4eea64b 100644 (file)
@@ -76,7 +76,7 @@ public class FairBlockingQueue<E> implements BlockingQueue<E> {
         lock.lock();
         try {
             result = items.poll();
-            if (result==null) {
+            if (result==null && timeout>0) {
                 ExchangeCountDownLatch<E> c = new ExchangeCountDownLatch<E>(1);
                 waiters.addLast(c);
                 lock.unlock();