summaryrefslogtreecommitdiff
path: root/sql/sql_select.cc
diff options
context:
space:
mode:
authorunknown <monty@mashka.mysql.fi>2002-12-05 16:38:49 +0200
committerunknown <monty@mashka.mysql.fi>2002-12-05 16:38:49 +0200
commitfdb093fc476af146feaa6d4403db0c25bb6484d8 (patch)
treee7064c81623ddc900c1933e03b9ce1c1fe234ff6 /sql/sql_select.cc
parent5fdd9f878f3b4690e3f6f0710e5930a81fcd368a (diff)
downloadmariadb-git-fdb093fc476af146feaa6d4403db0c25bb6484d8.tar.gz
Copy arguments given to mysql_server_init()
Made keybuff_size longlong (To make show variables work similar on 32 and 64 bit systems) Fixed some 'not initalized variable errors' in multi-table-update. Fixed memory leak in multi-table-update. Now all tests works under valgrind without any errors. libmysqld/lib_sql.cc: Copy arguments given to mysql_server_init() mysql-test/r/temp_table.result: Update test results (after merge form 3.23) sql/handler.cc: Made keybuff_size longlong sql/mysql_priv.h: Made keybuff_size longlong sql/mysqld.cc: Made keybuff_size longlong sql/set_var.cc: Made keybuff_size longlong sql/set_var.h: Made keybuff_size longlong sql/sql_select.cc: Simple cleanup sql/sql_select.h: Make TMP_TABLE_PARAM to be allocated through Sql_alloc sql/sql_update.cc: Fixed some 'not initalized variable errors' in multi-table-update. Fixed memory leak in multi-table-update
Diffstat (limited to 'sql/sql_select.cc')
-rw-r--r--sql/sql_select.cc10
1 files changed, 4 insertions, 6 deletions
diff --git a/sql/sql_select.cc b/sql/sql_select.cc
index 80b1ceb0538..c4bc10a8b2a 100644
--- a/sql/sql_select.cc
+++ b/sql/sql_select.cc
@@ -2848,9 +2848,7 @@ join_free(JOIN *join)
}
join->group_fields.delete_elements();
join->tmp_table_param.copy_funcs.delete_elements();
- if (join->tmp_table_param.copy_field) // Because of bug in ecc
- delete [] join->tmp_table_param.copy_field;
- join->tmp_table_param.copy_field=0;
+ join->tmp_table_param.cleanup();
DBUG_VOID_RETURN;
}
@@ -3699,13 +3697,13 @@ create_tmp_table(THD *thd,TMP_TABLE_PARAM *param,List<Item> &fields,
NullS))
{
bitmap_clear_bit(&temp_pool, temp_pool_slot);
- DBUG_RETURN(NULL); /* purecov: inspected */
+ DBUG_RETURN(NULL); /* purecov: inspected */
}
if (!(param->copy_field=copy=new Copy_field[field_count]))
{
bitmap_clear_bit(&temp_pool, temp_pool_slot);
- my_free((gptr) table,MYF(0)); /* purecov: inspected */
- DBUG_RETURN(NULL); /* purecov: inspected */
+ my_free((gptr) table,MYF(0)); /* purecov: inspected */
+ DBUG_RETURN(NULL); /* purecov: inspected */
}
param->funcs=copy_func;
strmov(tmpname,path);