From fd0abc890f99e2b5ca1b8ae4cb0dc3968eef1208 Mon Sep 17 00:00:00 2001 From: Nikita Malyavin Date: Wed, 29 Jul 2020 01:01:24 +1000 Subject: MDEV-18042 Server crashes upon adding a non-null date column under NO_ZERO_DATE with ALGORITHM=INPLACE accept table_name and db_name instead of table_share in make_truncated_value_warning --- sql/sql_table.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'sql/sql_table.cc') diff --git a/sql/sql_table.cc b/sql/sql_table.cc index b3a600eec36..57284272316 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -9952,7 +9952,8 @@ err_new_table_cleanup: thd->abort_on_warning= true; make_truncated_value_warning(thd, Sql_condition::WARN_LEVEL_WARN, f_val, strlength(f_val), t_type, - new_table->s, + alter_ctx.new_db, + alter_ctx.new_name, alter_ctx.datetime_field->field_name); thd->abort_on_warning= save_abort_on_warning; } -- cgit v1.2.1