summaryrefslogtreecommitdiff
path: root/sql/sql_view.cc
diff options
context:
space:
mode:
authorSergei Golubchik <sergii@pisem.net>2013-10-18 18:56:28 -0700
committerSergei Golubchik <sergii@pisem.net>2013-10-18 18:56:28 -0700
commitce68878947e4435540d4eca95bd5b3f1f5968b1b (patch)
tree5cbfdd5b6f959b33441f22f4063efb8aa40943fa /sql/sql_view.cc
parentcb9d3bec4645fc17be233d37677144926317f028 (diff)
downloadmariadb-git-ce68878947e4435540d4eca95bd5b3f1f5968b1b.tar.gz
fixes for embedded
Diffstat (limited to 'sql/sql_view.cc')
-rw-r--r--sql/sql_view.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/sql_view.cc b/sql/sql_view.cc
index 1a33cd97a48..336f501053d 100644
--- a/sql/sql_view.cc
+++ b/sql/sql_view.cc
@@ -1246,7 +1246,7 @@ bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table,
TABLE_LIST *view_tables= lex->query_tables;
TABLE_LIST *view_tables_tail= 0;
TABLE_LIST *tbl;
- Security_context *security_ctx;
+ Security_context *security_ctx= 0;
/*
Check rights to run commands (EXPLAIN SELECT & SHOW CREATE) which show
@@ -1421,6 +1421,7 @@ bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table,
if (view_select->options & OPTION_TO_QUERY_CACHE)
old_lex->select_lex.options|= OPTION_TO_QUERY_CACHE;
+#ifndef NO_EMBEDDED_ACCESS_CHECKS
if (table->view_suid)
{
/*
@@ -1441,6 +1442,7 @@ bool mysql_make_view(THD *thd, File_parser *parser, TABLE_LIST *table,
*/
security_ctx= table->security_ctx;
}
+#endif
/* Assign the context to the tables referenced in the view */
if (view_tables)