mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
MDEV-31403: Server crashes in st_join_table::choose_best_splitting
The code in choose_best_splitting() assumed that the join prefix is in join->positions[]. This is not necessarily the case. This function might be called when the join prefix is in join->best_positions[], too. Follow the approach from best_access_path(), which calls this function: pass the current join prefix as an argument, "const POSITION *join_positions" and use that.
This commit is contained in:
@ -7452,6 +7452,7 @@ best_access_path(JOIN *join,
|
||||
if (s->table->is_splittable())
|
||||
spl_plan= s->choose_best_splitting(idx,
|
||||
remaining_tables,
|
||||
join_positions,
|
||||
&spl_pd_boundary);
|
||||
|
||||
Json_writer_array trace_paths(thd, "considered_access_paths");
|
||||
|
Reference in New Issue
Block a user