3
0
Mirror von https://github.com/PaperMC/Velocity.git synchronisiert 2024-09-29 06:30:16 +02:00

Fix not forwarding channelReadComplete events in some cases

Dieser Commit ist enthalten in:
Andrew Steinborn 2021-08-04 23:01:28 -04:00
Ursprung d3e1b358fb
Commit c32bc88064

Datei anzeigen

@ -62,8 +62,12 @@ public class AutoReadHolderHandler extends ChannelDuplexHandler {
@Override
public void channelReadComplete(ChannelHandlerContext ctx) throws Exception {
if (this.queuedMessages.isEmpty()) {
ctx.fireChannelReadComplete();
if (ctx.channel().config().isAutoRead()) {
if (!this.queuedMessages.isEmpty()) {
this.drainQueuedMessages(ctx); // will also call fireChannelReadComplete()
} else {
ctx.fireChannelReadComplete();
}
}
}