HBASE-17431 Incorrect precheck condition in RoundRobinPool#get() (Jan Hentschel)
This commit is contained in:
parent
e8e40d8625
commit
d0393bdf28
|
@ -360,7 +360,7 @@ public class PoolMap<K, V> implements Map<K, V> {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public R get() {
|
public R get() {
|
||||||
if (super.size() < maxSize) {
|
if (super.size() <= 0) {
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
nextResource %= super.size();
|
nextResource %= super.size();
|
||||||
|
|
Loading…
Reference in New Issue