# | Line 468 | Line 468 | public class LinkedBlockingQueue<E> exte | |
---|---|---|
468 | if (removed) { | |
469 | p.item = null; | |
470 | trail.next = p.next; | |
471 | + | if (last == p) |
472 | + | last = trail; |
473 | if (count.getAndDecrement() == capacity) | |
474 | notFull.signalAll(); | |
475 | } | |
# | Line 672 | Line 674 | public class LinkedBlockingQueue<E> exte | |
674 | if (p == node) { | |
675 | p.item = null; | |
676 | trail.next = p.next; | |
677 | + | if (last == p) |
678 | + | last = trail; |
679 | int c = count.getAndDecrement(); | |
680 | if (c == capacity) | |
681 | notFull.signalAll(); |
– | Removed lines |
+ | Added lines |
< | Changed lines |
> | Changed lines |