mirror of
https://github.com/Eaglercraft-TeaVM-Fork/eagler-teavm.git
synced 2024-12-22 08:14:09 -08:00
Fixed NPE in LinkedList.remove(e)
This commit is contained in:
parent
f2fb5c7bd7
commit
eb2e08da3f
|
@ -343,10 +343,10 @@ public class TLinkedList<E> extends TAbstractSequentialList<E> implements TDeque
|
||||||
}
|
}
|
||||||
removeEntry(currentEntry);
|
removeEntry(currentEntry);
|
||||||
if (currentEntry == prevEntry) {
|
if (currentEntry == prevEntry) {
|
||||||
prevEntry = nextEntry.previous;
|
prevEntry = hasNext() ? nextEntry.previous : null;
|
||||||
--index;
|
--index;
|
||||||
} else if (currentEntry == nextEntry) {
|
} else if (currentEntry == nextEntry) {
|
||||||
nextEntry = prevEntry.next;
|
nextEntry = hasPrevious() ? prevEntry.next : null;
|
||||||
}
|
}
|
||||||
--size;
|
--size;
|
||||||
version = modCount;
|
version = modCount;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user