diff options
author | unknown <Sinisa@sinisa.nasamreza.org> | 2003-04-21 21:03:32 +0300 |
---|---|---|
committer | unknown <Sinisa@sinisa.nasamreza.org> | 2003-04-21 21:03:32 +0300 |
commit | 8078280c7664a385bccdf394f4927474ef738d98 (patch) | |
tree | 7a08a3618a847d9c0596c98295a731eff9e349b0 /sql/sql_lex.cc | |
parent | fa741bbc0316e9bdaeb1c3af416ed3dcf41b021f (diff) | |
download | mariadb-git-8078280c7664a385bccdf394f4927474ef738d98.tar.gz |
Fix for a bug record #307.
Very nasty bug.
It was caused by double free()-ing memory of join->select and
join->quick.
I was able to pinpoint it only after using Valgrind.
Plus better fix for bug with TMP_TABLE_PARAM.
Plus new constructor for SELECT_LEX.
mysql-test/r/innodb.result:
Fix for a bug record #307.
Very nasty bug.
It was caused by double free()-ing memory of join->select and
join->quick.
I was able to pinpoint it only after using Valgrind.
mysql-test/t/innodb.test:
Fix for a bug record #307.
Very nasty bug.
It was caused by double free()-ing memory of join->select and
join->quick.
I was able to pinpoint it only after using Valgrind.
sql/sql_lex.cc:
Adding a usefull constructor
sql/sql_lex.h:
Adding a usefull constructor which additionally required few more
definitions.
sql/sql_select.cc:
Fix for a bug record #307.
Very nasty bug.
It was caused by double free()-ing memory of join->select and
join->quick.
I was able to pinpoint it only after using Valgrind.
sql/sql_union.cc:
Fixing bug #307.
Also, a better fix for TMP_TABLE_PARAM bug.
Also, use of the new constructor for SELECT_LEX.
Diffstat (limited to 'sql/sql_lex.cc')
-rw-r--r-- | sql/sql_lex.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/sql/sql_lex.cc b/sql/sql_lex.cc index d5d438fc3a1..ec77668c968 100644 --- a/sql/sql_lex.cc +++ b/sql/sql_lex.cc @@ -1365,6 +1365,17 @@ ulong st_select_lex::get_table_join_options() return table_join_options; } +st_select_lex::st_select_lex(struct st_lex *lex) +{ + select_number= ++lex->thd->select_number; + init_query(); + init_select(); + include_neighbour(lex->current_select); + include_global((st_select_lex_node**)&lex->all_selects_list); + lex->current_select= this; +} + + /* There are st_select_lex::add_table_to_list & st_select_lex::set_lock_for_tables in sql_parse.cc |