Fix packet length assertion

The `used_len + len` can be the same as `total_len`.
This commit is contained in:
Markus Mäkelä 2019-06-26 09:19:24 +03:00
parent 88dae197b0
commit 67d82146f1
No known key found for this signature in database
GPG Key ID: 72D48FCE664F7B19

View File

@ -295,7 +295,7 @@ void RWBackend::process_packets(GWBUF* result)
len |= (*it++) << 16;
++it; // Skip the sequence
mxb_assert(it != buffer.end());
mxb_assert(used_len + len < total_len);
mxb_assert(used_len + len <= total_len);
MXB_AT_DEBUG(used_len += len);
auto end = it;
end.advance(len);