Default readArray to capping to readableBytes instead of Short.MAX_VALUE
This commit is contained in:
parent
1dda27e19b
commit
7179dd4c0d
@ -42,7 +42,7 @@ public abstract class DefinedPacket
|
||||
|
||||
public static byte[] readArray(ByteBuf buf)
|
||||
{
|
||||
return readArray( buf, Short.MAX_VALUE );
|
||||
return readArray( buf, buf.readableBytes() );
|
||||
}
|
||||
|
||||
public static byte[] readArray(ByteBuf buf, int limit)
|
||||
|
Loading…
Reference in New Issue
Block a user