public int Read(byte[] buffer, int offset, int count, bool exact= true) { int len = _buffer.Read(buffer, offset, count); if (len != count && exact) throw new PacketLengthException(); return len; }