Skip to content
Permalink
Browse files

MDEV-19175 Server crashes in ha_partition::vers_can_native upon INSER…

…T DELAYED into versioned partitioned table

Uninitialized LEX::part_info on ha_partition::vers_can_native().
  • Loading branch information...
midenok committed May 27, 2019
1 parent c7f8189 commit af5b0dbab6f4dbd83cb38031286916adbb1827a4
@@ -549,6 +549,11 @@ t1 CREATE TABLE `t1` (
PARTITION BY SYSTEM_TIME INTERVAL 7 SECOND
(PARTITION `ver_p1` HISTORY ENGINE = DEFAULT_ENGINE,
PARTITION `ver_pn` CURRENT ENGINE = DEFAULT_ENGINE)
#
# MDEV-19175 Server crashes in ha_partition::vers_can_native upon INSERT DELAYED into versioned partitioned table
#
create or replace table t1 (f int) with system versioning partition by hash(f);
insert delayed into t1 values (1);
# Test cleanup
drop database test;
create database test;
@@ -480,6 +480,14 @@ partition by system_time interval column_get(column_create(7,7), 7 as int) secon
--replace_result $default_engine DEFAULT_ENGINE
show create table t1;

--echo #
--echo # MDEV-19175 Server crashes in ha_partition::vers_can_native upon INSERT DELAYED into versioned partitioned table
--echo #
create or replace table t1 (f int) with system versioning partition by hash(f);
# delayed works differently in embedded server
--error 0,ER_DELAYED_NOT_SUPPORTED
insert delayed into t1 values (1);

--echo # Test cleanup
drop database test;
create database test;
@@ -3225,7 +3225,7 @@ void Query_tables_list::destroy_query_tables_list()
*/

LEX::LEX()
: explain(NULL), result(0), arena_for_set_stmt(0), mem_root_for_set_stmt(0),
: explain(NULL), result(0), part_info(NULL), arena_for_set_stmt(0), mem_root_for_set_stmt(0),
option_type(OPT_DEFAULT), context_analysis_only(0), sphead(0),
default_used(0), is_lex_started(0), limit_rows_examined_cnt(ULONGLONG_MAX)
{

0 comments on commit af5b0db

Please sign in to comment.
You can’t perform that action at this time.