summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <evgen@sunlight.local>2006-08-09 06:46:06 +0400
committerunknown <evgen@sunlight.local>2006-08-09 06:46:06 +0400
commit4abe4b1717b099dbf3502e041c246b196622a23f (patch)
tree3e9810afbf258fbd8840a6bf815fdc52a03d4073
parenta5ccdea7726529a1f8ecb122b1db0994c60d4d35 (diff)
downloadmariadb-git-4abe4b1717b099dbf3502e041c246b196622a23f.tar.gz
sql_view.cc:
After merge fix sql/sql_view.cc: After merge fix
-rw-r--r--sql/sql_view.cc14
1 files changed, 1 insertions, 13 deletions
diff --git a/sql/sql_view.cc b/sql/sql_view.cc
index 8c4f188a840..16ee6505886 100644
--- a/sql/sql_view.cc
+++ b/sql/sql_view.cc
@@ -179,23 +179,16 @@ static bool
fill_defined_view_parts (THD *thd, TABLE_LIST *view)
{
LEX *lex= thd->lex;
- bool free_view= 1;
+ bool not_used;
TABLE_LIST decoy;
- if (view->view)
- free_view= 0;
memcpy (&decoy, view, sizeof (TABLE_LIST));
if (!open_table(thd, &decoy, thd->mem_root, &not_used, OPEN_VIEW_NO_PARSE) &&
!decoy.view)
{
/* It's a table */
- my_free((gptr)decoy.table, MYF(0));
- my_error(ER_WRONG_OBJECT, MYF(0), view->db, view->table_name, "VIEW");
return TRUE;
}
- if (!decoy.view)
- /* An error while opening the view occurs, caller will handle it */
- return FALSE;
if (!lex->definer)
{
@@ -208,11 +201,6 @@ fill_defined_view_parts (THD *thd, TABLE_LIST *view)
if (lex->create_view_suid == VIEW_SUID_DEFAULT)
lex->create_view_suid= decoy.view_suid ?
VIEW_SUID_DEFINER : VIEW_SUID_INVOKER;
- if (free_view)
- {
- delete decoy.view;
- lex->cleanup_after_one_table_open();
- }
return FALSE;
}