Fix buffer end pointer comparison in maxavro
The buffer pointer can point to the end pointer if it is the last value in the buffer.
This commit is contained in:
parent
ce3d7acf2d
commit
4716f5b48f
@ -144,7 +144,7 @@ char* maxavro_read_string(MAXAVRO_FILE* file, size_t* size)
|
||||
|
||||
if (maxavro_read_integer(file, &len))
|
||||
{
|
||||
if (file->buffer_ptr + len < file->buffer_end)
|
||||
if (file->buffer_ptr + len <= file->buffer_end)
|
||||
{
|
||||
key = MXS_MALLOC(len + 1);
|
||||
if (key)
|
||||
|
Loading…
x
Reference in New Issue
Block a user