8193300: Miscellaneous changes imported from jsr166 CVS 2018-01

Reviewed-by: martin
This commit is contained in:
Doug Lea 2018-01-16 18:28:39 -08:00
parent c19d18871c
commit d771fc3a6b
149 changed files with 872 additions and 571 deletions

View file

@ -269,8 +269,8 @@ public class PriorityBlockingQueue<E> extends AbstractQueue<E>
if (a.getClass() != Object[].class)
a = Arrays.copyOf(a, n, Object[].class);
if (screen && (n == 1 || this.comparator != null)) {
for (int i = 0; i < n; ++i)
if (a[i] == null)
for (Object elt : a)
if (elt == null)
throw new NullPointerException();
}
this.queue = a;