From 26be0566f41e52b01b64d00043e4dda4d2bf6e68 Mon Sep 17 00:00:00 2001 From: md_5 Date: Sat, 12 Oct 2013 15:29:39 +1100 Subject: [PATCH] I love @Cobi --- .../main/java/net/md_5/bungee/protocol/MinecraftDecoder.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/protocol/src/main/java/net/md_5/bungee/protocol/MinecraftDecoder.java b/protocol/src/main/java/net/md_5/bungee/protocol/MinecraftDecoder.java index 4ecb7a4e..1c6476fe 100644 --- a/protocol/src/main/java/net/md_5/bungee/protocol/MinecraftDecoder.java +++ b/protocol/src/main/java/net/md_5/bungee/protocol/MinecraftDecoder.java @@ -32,8 +32,11 @@ public class MinecraftDecoder extends ByteToMessageDecoder if ( in.readableBytes() != 0 ) { System.out.println( in.toString( Charsets.UTF_8 ) ); - // throw new BadPacketException( "Did not read all bytes from packet " + packet.getClass() + " " + packetId + " Protocol " + protocol + " Direction " + prot ); + // throw new BadPacketException( "Did not read all bytes from packet " + packet.getClass() + " " + packetId + " Protocol " + protocol + " Direction " + prot ); } + } else + { + in.skipBytes( in.readableBytes() ); } out.add( new PacketWrapper( packet, copy ) );