diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2021-04-21 10:20:20 +0300 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2021-04-21 10:20:20 +0300 |
commit | 28f01f82e1cb682566017b52017469be7638dd49 (patch) | |
tree | d496cb0936d25973b95f6eb591508c2e493032b8 /sql/sql_base.cc | |
parent | a3099a3b4a394da360b5c1e7ae6dc985ae2f7f2f (diff) | |
parent | 80ed136e6dd4a021b1fc9b7bd7077bf989c3d247 (diff) | |
download | mariadb-git-bb-10.6-merge.tar.gz |
WIP merge 10.5 to 10.6bb-10.6-merge
FIXME: Disabled tests due to upgrading libmariadb:
main.mysql_client_test main.mysql_client_test_nonblock main.mysql_client_test_comp
Diffstat (limited to 'sql/sql_base.cc')
-rw-r--r-- | sql/sql_base.cc | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/sql/sql_base.cc b/sql/sql_base.cc index 9a4dea3a216..16d1440dcb9 100644 --- a/sql/sql_base.cc +++ b/sql/sql_base.cc @@ -7849,11 +7849,15 @@ bool setup_tables(THD *thd, Name_resolution_context *context, DBUG_RETURN(1); } tablenr++; - } - if (tablenr > MAX_TABLES) - { - my_error(ER_TOO_MANY_TABLES,MYF(0), static_cast<int>(MAX_TABLES)); - DBUG_RETURN(1); + /* + We test the max tables here as we setup_table_map() should not be called + with tablenr >= 64 + */ + if (tablenr > MAX_TABLES) + { + my_error(ER_TOO_MANY_TABLES,MYF(0), static_cast<int>(MAX_TABLES)); + DBUG_RETURN(1); + } } } else |