summaryrefslogtreecommitdiff
path: root/sql/sql_rename.cc
diff options
context:
space:
mode:
authorJan Lindström <jan.lindstrom@mariadb.com>2020-04-28 16:20:24 +0300
committerJan Lindström <jan.lindstrom@mariadb.com>2020-04-28 16:20:24 +0300
commit25cb2b373c84b09a7b1720704e85c64d3df90f16 (patch)
tree9321274455993c7abe2bd8ad65111b038d5bec8a /sql/sql_rename.cc
parente545a60bf41bf6efe1e9d7730cc474bda9d3fc62 (diff)
downloadmariadb-git-25cb2b373c84b09a7b1720704e85c64d3df90f16.tar.gz
MDEV-22128 : Server with wsrep_on crashes in do_rename upon RENAME TABLE on a view
We need to make sure that hton is not same as view_pseudo_hton that is not NULL but not usable.
Diffstat (limited to 'sql/sql_rename.cc')
-rw-r--r--sql/sql_rename.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/sql_rename.cc b/sql/sql_rename.cc
index 5fafd9fa28a..0ac97bbeafd 100644
--- a/sql/sql_rename.cc
+++ b/sql/sql_rename.cc
@@ -323,7 +323,7 @@ do_rename(THD *thd, TABLE_LIST *ren_table, const LEX_CSTRING *new_db,
DBUG_ASSERT(!thd->locked_tables_mode);
#ifdef WITH_WSREP
- if (WSREP(thd) && hton &&
+ if (WSREP(thd) && hton && hton != view_pseudo_hton &&
!wsrep_should_replicate_ddl(thd, hton->db_type))
DBUG_RETURN(1);
#endif