From d23566996702989a484bb0b2393afa91d39e10d4 Mon Sep 17 00:00:00 2001 From: Aleksey Midenkov Date: Wed, 18 Jan 2023 16:52:16 +0300 Subject: MDEV-29767 Cleanup: removed create_like_options() That filter only adds problems not making any useful feature. --- sql/sql_table.cc | 2 +- sql/structs.h | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/sql/sql_table.cc b/sql/sql_table.cc index cf8ec9260c5..db00b66f575 100644 --- a/sql/sql_table.cc +++ b/sql/sql_table.cc @@ -5745,7 +5745,7 @@ bool mysql_create_like_table(THD* thd, TABLE_LIST* table, Set OR REPLACE and IF NOT EXISTS option as in the CREATE TABLE LIKE statement. */ - local_create_info.init(create_info->create_like_options()); + local_create_info.init(create_info->get_options()); local_create_info.db_type= src_table->table->s->db_type(); local_create_info.row_type= src_table->table->s->row_type; local_create_info.alter_info= &local_alter_info; diff --git a/sql/structs.h b/sql/structs.h index 5185210b403..a32e25e31c7 100644 --- a/sql/structs.h +++ b/sql/structs.h @@ -546,12 +546,9 @@ private: Options m_options; public: - Options create_like_options() const + Options get_options() const { - return (DDL_options_st::Options) - /* TODO: that filter is only adding problems, remove it */ - (((uint) m_options) & (OPT_IF_NOT_EXISTS | OPT_OR_REPLACE | - OPT_OR_REPLACE_SLAVE_GENERATED)); + return m_options; } void init() { m_options= OPT_NONE; } void init(Options options) { m_options= options; } -- cgit v1.2.1