Commit b43b8c24 authored by Mattias Jonsson's avatar Mattias Jonsson

Bug#40972: Partition pruning can lead to crash for bad dates

post push fix, added test found a valgrind warning
parent b727dab9
...@@ -6678,6 +6678,7 @@ int get_part_iter_for_interval_via_mapping(partition_info *part_info, ...@@ -6678,6 +6678,7 @@ int get_part_iter_for_interval_via_mapping(partition_info *part_info,
uint32 max_endpoint_val; uint32 max_endpoint_val;
get_endpoint_func get_endpoint; get_endpoint_func get_endpoint;
uint field_len= field->pack_length_in_rec(); uint field_len= field->pack_length_in_rec();
part_iter->ret_null_part= part_iter->ret_null_part_orig= FALSE;
if (part_info->part_type == RANGE_PARTITION) if (part_info->part_type == RANGE_PARTITION)
{ {
...@@ -6698,7 +6699,6 @@ int get_part_iter_for_interval_via_mapping(partition_info *part_info, ...@@ -6698,7 +6699,6 @@ int get_part_iter_for_interval_via_mapping(partition_info *part_info,
max_endpoint_val= part_info->no_list_values; max_endpoint_val= part_info->no_list_values;
part_iter->get_next= get_next_partition_id_list; part_iter->get_next= get_next_partition_id_list;
part_iter->part_info= part_info; part_iter->part_info= part_info;
part_iter->ret_null_part= part_iter->ret_null_part_orig= FALSE;
if (max_endpoint_val == 0) if (max_endpoint_val == 0)
{ {
/* /*
......
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