if (size == -1) {
<BUG>return null;
}</BUG>
ByteBuffer buffer = is.slice();
<BUG>buffer.limit(size);

is.position(is.position() + size);
</BUG>
int cr = is.get();
int lf = is.get();

if (size == -1) {
return null;
} else if (size > Integer.MAX_VALUE) {
throw new IOException("Value too large");
}
ByteBuffer buffer = is.slice();
buffer.limit((int) size);
is.position(is.position() + (int) size);
int cr = is.get();
int lf = is.get();
