diff --git a/proxy/src/main/java/net/md_5/bungee/netty/CipherBase.java b/proxy/src/main/java/net/md_5/bungee/netty/CipherBase.java index 55eef908..f5999cdc 100644 --- a/proxy/src/main/java/net/md_5/bungee/netty/CipherBase.java +++ b/proxy/src/main/java/net/md_5/bungee/netty/CipherBase.java @@ -38,6 +38,7 @@ public class CipherBase if ( heapIn.length < readableBytes ) { heapIn = new byte[ readableBytes ]; + heapInLocal.set( heapIn ); } in.readBytes( heapIn, 0, readableBytes ); @@ -46,6 +47,7 @@ public class CipherBase if ( heapOut.length < outputSize ) { heapOut = new byte[ outputSize ]; + heapOutLocal.set( heapOut ); } out.writeBytes( heapOut, 0, cipher.update( heapIn, 0, readableBytes, heapOut ) ); }