summaryrefslogtreecommitdiff
path: root/sql/sql_parse.h
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mnogosearch.org>2013-04-18 23:18:34 +0400
committerAlexander Barkov <bar@mnogosearch.org>2013-04-18 23:18:34 +0400
commit3975256685b084b39d6e1dd750c131ad98c069c2 (patch)
tree14eb904d4632614c4d9066b9d4c08e2053b38ce6 /sql/sql_parse.h
parent89bafdf452a13a0fe10e81eb03d4134d2a69dd9e (diff)
downloadmariadb-git-3975256685b084b39d6e1dd750c131ad98c069c2.tar.gz
Fixing check_access() not to be inlined in case of
embedded server, to make connect engine work with embedded server dynamically. modified: sql/sql_parse.cc sql/sql_parse.h
Diffstat (limited to 'sql/sql_parse.h')
-rw-r--r--sql/sql_parse.h19
1 files changed, 9 insertions, 10 deletions
diff --git a/sql/sql_parse.h b/sql/sql_parse.h
index 4510ebe94e2..fd52fb20ea7 100644
--- a/sql/sql_parse.h
+++ b/sql/sql_parse.h
@@ -147,6 +147,15 @@ inline bool check_identifier_name(LEX_STRING *str)
return check_identifier_name(str, NAME_CHAR_LEN, 0, "");
}
+
+/*
+ check_access() is needed for the connect engine.
+ It cannot be inlined - it must be exported.
+*/
+bool check_access(THD *thd, ulong want_access, const char *db, ulong *save_priv,
+ GRANT_INTERNAL_INFO *grant_internal_info,
+ bool dont_check_global_grants, bool no_errors);
+
#ifndef NO_EMBEDDED_ACCESS_CHECKS
bool check_one_table_access(THD *thd, ulong privilege, TABLE_LIST *tables);
bool check_single_table_access(THD *thd, ulong privilege,
@@ -155,9 +164,6 @@ bool check_routine_access(THD *thd,ulong want_access,char *db,char *name,
bool is_proc, bool no_errors);
bool check_some_access(THD *thd, ulong want_access, TABLE_LIST *table);
bool check_some_routine_access(THD *thd, const char *db, const char *name, bool is_proc);
-bool check_access(THD *thd, ulong want_access, const char *db, ulong *save_priv,
- GRANT_INTERNAL_INFO *grant_internal_info,
- bool dont_check_global_grants, bool no_errors);
bool check_table_access(THD *thd, ulong requirements,TABLE_LIST *tables,
bool any_combination_of_privileges_will_do,
uint number,
@@ -179,13 +185,6 @@ inline bool check_some_access(THD *thd, ulong want_access, TABLE_LIST *table)
inline bool check_some_routine_access(THD *thd, const char *db,
const char *name, bool is_proc)
{ return false; }
-inline bool check_access(THD *, ulong, const char *, ulong *save_priv,
- GRANT_INTERNAL_INFO *, bool, bool)
-{
- if (save_priv)
- *save_priv= GLOBAL_ACLS;
- return false;
-}
inline bool
check_table_access(THD *thd, ulong requirements,TABLE_LIST *tables,
bool any_combination_of_privileges_will_do,