Commit 6f2ca4ea authored by Marko Mäkelä's avatar Marko Mäkelä

MDEV-21263: Fix -Wclass-memaccess

Since commit f52bf920 the type
Sql_sort is non-trivial, because it includes a data member
Bounds_checked_array<SORT_FIELD> local_sortorder.
There still is no vtable, so memset() is safe to invoke, but
we must add a cast to silence a warning in GCC 8 or later.
parent 39e4fe8f
......@@ -300,7 +300,7 @@ class Sort_param {
Sort_param()
{
memset(this, 0, sizeof(*this));
memset(reinterpret_cast<void*>(this), 0, sizeof(*this));
}
void init_for_filesort(uint sortlen, TABLE *table,
ha_rows maxrows, bool sort_positions);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment