Fix eternal loop in Recycler.WeakOrderQueue.Head#run() that blocks ObjectCleaner thread (#7878)

Motivation:

When trying to cleanup WeakOrderQueue by the ObjectCleaner we end up in an endless loop which will cause the ObjectCleaner to be not able to cleanup any other resources anymore.This bug was introduced by 6eb9674bf5.

Modifications:

Correctly update link while cleanup

Result:

Fixes https://github.com/netty/netty/issues/7877
This commit is contained in:
Norman Maurer 2018-04-19 09:40:38 +02:00 committed by GitHub
parent 0f34d887b7
commit 3ec29455af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -261,7 +261,7 @@ public abstract class Recycler<T> {
Link head = link;
while (head != null) {
reclaimSpace(LINK_CAPACITY);
head = link.next;
head = head.next;
}
}