readableBytes() ==0 -> !isReadable()

This commit is contained in:
Trustin Lee 2013-12-06 13:29:46 +09:00
parent 27d020fc35
commit 6554b8c395

View File

@ -50,7 +50,7 @@ public abstract class BinaryMemcacheEncoder<M extends BinaryMemcacheMessage<H>,
* @param extras the extras to encode.
*/
private static void encodeExtras(ByteBuf buf, ByteBuf extras) {
if (extras == null || extras.readableBytes() == 0) {
if (extras == null || !extras.isReadable()) {
return;
}