mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
sql_base.cc, unireg.h, sql_lex.h, table.cc, sql_view.h, sql_view.cc:
Correct memory leak fix sql/unireg.h: Correct memory leak fix sql/table.cc: Correct memory leak fix sql/sql_view.h: Correct memory leak fix sql/sql_view.cc: Correct memory leak fix sql/sql_lex.h: Correct memory leak fix sql/sql_base.cc: Correct memory leak fix
This commit is contained in:
@@ -183,7 +183,7 @@ fill_defined_view_parts (THD *thd, TABLE_LIST *view)
|
||||
TABLE_LIST decoy;
|
||||
|
||||
memcpy (&decoy, view, sizeof (TABLE_LIST));
|
||||
if (!open_table(thd, &decoy, thd->mem_root, ¬_used, 0) &&
|
||||
if (!open_table(thd, &decoy, thd->mem_root, ¬_used, OPEN_VIEW_NO_PARSE) &&
|
||||
!decoy.view)
|
||||
{
|
||||
return TRUE;
|
||||
@@ -815,13 +815,14 @@ loop_out:
|
||||
thd Thread handler
|
||||
parser parser object
|
||||
table TABLE_LIST structure for filling
|
||||
|
||||
flags flags
|
||||
RETURN
|
||||
0 ok
|
||||
1 error
|
||||
*/
|
||||
|
||||
bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table)
|
||||
bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table,
|
||||
uint flags)
|
||||
{
|
||||
SELECT_LEX *end, *view_select;
|
||||
LEX *old_lex, *lex;
|
||||
@@ -912,6 +913,10 @@ bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table)
|
||||
table->db, table->table_name);
|
||||
get_default_definer(thd, &table->definer);
|
||||
}
|
||||
if (flags & OPEN_VIEW_NO_PARSE)
|
||||
{
|
||||
DBUG_RETURN(FALSE);
|
||||
}
|
||||
|
||||
/*
|
||||
Save VIEW parameters, which will be wiped out by derived table
|
||||
|
||||
Reference in New Issue
Block a user