diff options
author | Aleksey Midenkov <midenok@gmail.com> | 2021-10-11 13:36:07 +0300 |
---|---|---|
committer | Aleksey Midenkov <midenok@gmail.com> | 2021-10-11 13:36:07 +0300 |
commit | d31f953789def34f20d29b31add847a3c30a8ecc (patch) | |
tree | ddec3c452cb3af1c9dd83b02a899b5bd31b981f2 /sql/handler.cc | |
parent | 911c803db19de7ffd45c39ff3614abcf19c63536 (diff) | |
download | mariadb-git-d31f953789def34f20d29b31add847a3c30a8ecc.tar.gz |
MDEV-22660 SIGSEGV on adding system versioning and modifying system column
Second alter subcommand correctly removed VERS_ROW_END flag. We throw
ER_VERS_PERIOD_COLUMNS in such case.
Diffstat (limited to 'sql/handler.cc')
-rw-r--r-- | sql/handler.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/sql/handler.cc b/sql/handler.cc index f46e51a34ce..bbd0f3bf515 100644 --- a/sql/handler.cc +++ b/sql/handler.cc @@ -7564,6 +7564,12 @@ bool Vers_parse_info::check_sys_fields(const Lex_table_name &table_name, row_end= f; } + if (!row_start || !row_end) + { + my_error(ER_VERS_PERIOD_COLUMNS, MYF(0), as_row.start.str, as_row.end.str); + return true; + } + if (!can_native || !row_start->is_some_bigint() || !row_end->is_some_bigint()) |