There is no commit here - fix compression

Signed-off-by: TheMode <themode@outlook.fr>
This commit is contained in:
TheMode 2021-09-07 01:31:34 +02:00
parent 8f1e84ffdb
commit adf1023e35

View File

@ -198,7 +198,7 @@ public final class PacketUtils {
if (packetSize >= MinecraftServer.getCompressionThreshold()) {
// Packet large enough, compress
buffer.position(contentStart);
final ByteBuffer uncompressedContent = buffer.slice().limit(contentStart + packetSize);
final ByteBuffer uncompressedContent = buffer.slice().limit(packetSize);
final ByteBuffer uncompressedCopy = localBuffer().put(uncompressedContent).flip();
Deflater deflater = COMPRESSOR.get();