diff options
author | Varun Gupta <varun.gupta@mariadb.com> | 2020-12-14 16:51:30 +0530 |
---|---|---|
committer | Varun Gupta <varun.gupta@mariadb.com> | 2020-12-14 16:51:30 +0530 |
commit | e5d88e03beec38973539f5d290fa70f81be645ef (patch) | |
tree | dcdfbba922d0e6df8ddd7eb083755dd6a7a38e2c /sql/opt_split.cc | |
parent | 18256bce23a5e219a8f4424b56a4380cf8be330a (diff) | |
download | mariadb-git-e5d88e03beec38973539f5d290fa70f81be645ef.tar.gz |
MDEV-22740: UBSAN: sql/opt_split.cc:1150:28: runtime error: shift exponent 61 is too large for 32-bit type 'int' (on optimized builds)
Use a ulonglong instead of uint when left shifting to calculate the table map for all the tables in a query
Diffstat (limited to 'sql/opt_split.cc')
-rw-r--r-- | sql/opt_split.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/opt_split.cc b/sql/opt_split.cc index 6807a623b73..fd7836f55cc 100644 --- a/sql/opt_split.cc +++ b/sql/opt_split.cc @@ -1149,7 +1149,7 @@ bool JOIN_TAB::fix_splitting(SplM_plan_info *spl_plan, bool JOIN::fix_all_splittings_in_plan() { table_map prev_tables= 0; - table_map all_tables= (1 << table_count) - 1; + table_map all_tables= (table_map(1) << table_count) - 1; for (uint tablenr= 0; tablenr < table_count; tablenr++) { POSITION *cur_pos= &best_positions[tablenr]; |