diff --git a/src/de/steamwar/sql/internal/Statement.java b/src/de/steamwar/sql/internal/Statement.java index f78f0d4..e842d5f 100644 --- a/src/de/steamwar/sql/internal/Statement.java +++ b/src/de/steamwar/sql/internal/Statement.java @@ -234,7 +234,7 @@ public class Statement implements AutoCloseable { private static Connection aquireConnection() { synchronized (connections) { - if(connections.isEmpty() && connectionBudget == 0) + while(connections.isEmpty() && connectionBudget == 0) waitOnConnections(); if(!connections.isEmpty()) {