Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-11-20 06:50:08 +01:00
fix decoder
Dieser Commit ist enthalten in:
Ursprung
485f4fa070
Commit
bcb76350a1
@ -34,14 +34,14 @@ public class VelocityDecodeHandler extends MessageToMessageDecoder<ByteBuf> {
|
|||||||
|
|
||||||
ByteBuf transformedBuf = ctx.alloc().buffer().writeBytes(bytebuf);
|
ByteBuf transformedBuf = ctx.alloc().buffer().writeBytes(bytebuf);
|
||||||
try {
|
try {
|
||||||
boolean needsCompress = handleCompressionOrder(ctx, bytebuf);
|
boolean needsCompress = handleCompressionOrder(ctx, transformedBuf);
|
||||||
|
|
||||||
info.transformIncoming(bytebuf, CancelDecoderException::generate);
|
info.transformIncoming(transformedBuf, CancelDecoderException::generate);
|
||||||
|
|
||||||
if (needsCompress) {
|
if (needsCompress) {
|
||||||
recompress(ctx, bytebuf);
|
recompress(ctx, transformedBuf);
|
||||||
}
|
}
|
||||||
out.add(bytebuf.retain());
|
out.add(transformedBuf.retain());
|
||||||
} finally {
|
} finally {
|
||||||
transformedBuf.release();
|
transformedBuf.release();
|
||||||
}
|
}
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren