summaryrefslogtreecommitdiff
path: root/sql/sql_view.cc
diff options
context:
space:
mode:
authorKonstantin Osipov <kostja@sun.com>2010-02-04 00:48:40 +0300
committerKonstantin Osipov <kostja@sun.com>2010-02-04 00:48:40 +0300
commitf30d17e078dab10c8beded9a1c9b476dd4c67be9 (patch)
tree737674a83beb16e444848c8c4a66a3de08696065 /sql/sql_view.cc
parent1397985d53b575ed51b51568a12695949ab00698 (diff)
parentb6685d35dcc45e4fc8eca53fa8f6d3315f2e6b89 (diff)
downloadmariadb-git-f30d17e078dab10c8beded9a1c9b476dd4c67be9.tar.gz
Merge next-mr -> next-4284.
Diffstat (limited to 'sql/sql_view.cc')
-rw-r--r--sql/sql_view.cc17
1 files changed, 10 insertions, 7 deletions
diff --git a/sql/sql_view.cc b/sql/sql_view.cc
index 84418d6b629..6179d23ecfd 100644
--- a/sql/sql_view.cc
+++ b/sql/sql_view.cc
@@ -1122,8 +1122,18 @@ bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table,
table->db, table->table_name);
get_default_definer(thd, &table->definer);
}
+
+ /*
+ Initialize view definition context by character set names loaded from
+ the view definition file. Use UTF8 character set if view definition
+ file is of old version and does not contain the character set names.
+ */
+ table->view_creation_ctx= View_creation_ctx::create(thd, table);
+
if (flags & OPEN_VIEW_NO_PARSE)
{
+ if (arena)
+ thd->restore_active_arena(arena, &backup);
DBUG_RETURN(FALSE);
}
@@ -1152,13 +1162,6 @@ bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table,
/*TODO: md5 test here and warning if it is differ */
- /*
- Initialize view definition context by character set names loaded from
- the view definition file. Use UTF8 character set if view definition
- file is of old version and does not contain the character set names.
- */
-
- table->view_creation_ctx= View_creation_ctx::create(thd, table);
/*
TODO: TABLE mem root should be used here when VIEW will be stored in