diff options
author | serg@serg.mylan <> | 2006-01-03 17:54:54 +0100 |
---|---|---|
committer | serg@serg.mylan <> | 2006-01-03 17:54:54 +0100 |
commit | 14f94dc0cad1419e74047956c059c1cf9c3e7a2c (patch) | |
tree | 2c671047ec7c4161ca04e53f5f54c6797f81afd4 /sql/opt_range.cc | |
parent | 04cff0d055fd63d7f0a9395478171e735799f30b (diff) | |
download | mariadb-git-14f94dc0cad1419e74047956c059c1cf9c3e7a2c.tar.gz |
many warnings (practically safe but annoying) corrected
Diffstat (limited to 'sql/opt_range.cc')
-rw-r--r-- | sql/opt_range.cc | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/sql/opt_range.cc b/sql/opt_range.cc index d9a608eb064..9a44b6e1cab 100644 --- a/sql/opt_range.cc +++ b/sql/opt_range.cc @@ -652,7 +652,6 @@ SQL_SELECT *make_select(TABLE *head, table_map const_tables, table_map read_tables, COND *conds, bool allow_null_cond, int *error) - { SQL_SELECT *select; DBUG_ENTER("make_select"); @@ -5774,10 +5773,7 @@ QUICK_RANGE_SELECT *get_quick_select_for_ref(THD *thd, TABLE *table, if (!quick) return 0; /* no ranges found */ if (quick->init()) - { - delete quick; goto err; - } quick->records= records; if (cp_buffer_from_ref(thd,ref) && thd->is_fatal_error || @@ -7111,7 +7107,7 @@ get_best_group_min_max(PARAM *param, SEL_TREE *tree) ha_rows cur_records; SEL_ARG *cur_index_tree= NULL; ha_rows cur_quick_prefix_records= 0; - uint cur_param_idx; + uint cur_param_idx=MAX_KEY; key_map cur_used_key_parts; uint pk= param->table->s->primary_key; @@ -7327,6 +7323,7 @@ get_best_group_min_max(PARAM *param, SEL_TREE *tree) */ if (cur_read_cost < best_read_cost - (DBL_EPSILON * cur_read_cost)) { + DBUG_ASSERT(tree != 0 || cur_param_idx == MAX_KEY); index_info= cur_index_info; index= cur_index; best_read_cost= cur_read_cost; |