mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
MDEV-22387: Do not violate __attribute__((nonnull))
This follows up commit commit94a520ddbe
and commit7c5519c12d
. After these changes, the default test suites on a cmake -DWITH_UBSAN=ON build no longer fail due to passing null pointers as parameters that are declared to never be null, but plenty of other runtime errors remain.
This commit is contained in:
@ -1395,7 +1395,8 @@ uint JOIN_CACHE::write_record_data(uchar * link, bool *is_full)
|
||||
blob_field->get_image(cp, copy->length,
|
||||
blob_field->charset());
|
||||
DBUG_ASSERT(cp + copy->length + copy->blob_length <= buff + buff_size);
|
||||
memcpy(cp+copy->length, copy->str, copy->blob_length);
|
||||
if (copy->blob_length)
|
||||
memcpy(cp+copy->length, copy->str, copy->blob_length);
|
||||
cp+= copy->length+copy->blob_length;
|
||||
}
|
||||
break;
|
||||
|
Reference in New Issue
Block a user