summaryrefslogtreecommitdiff
path: root/sql/log.cc
diff options
context:
space:
mode:
Diffstat (limited to 'sql/log.cc')
-rw-r--r--sql/log.cc14
1 files changed, 10 insertions, 4 deletions
diff --git a/sql/log.cc b/sql/log.cc
index 33464d0ab29..32273a4ac80 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -1093,8 +1093,11 @@ bool MYSQL_LOG::write(THD *thd,enum enum_server_command command,
if (thd)
{ // Normal thread
- if ((thd->options & OPTION_LOG_OFF) &&
- (thd->master_access & SUPER_ACL))
+ if ((thd->options & OPTION_LOG_OFF)
+#ifndef NO_EMBEDDED_ACCESS_CHECKS
+ && (thd->master_access & SUPER_ACL)
+#endif
+)
{
VOID(pthread_mutex_unlock(&LOCK_log));
return 0; // No logging
@@ -1553,8 +1556,11 @@ bool MYSQL_LOG::write(THD *thd,const char *query, uint query_length,
int tmp_errno=0;
char buff[80],*end;
end=buff;
- if (!(thd->options & OPTION_UPDATE_LOG) &&
- (thd->master_access & SUPER_ACL))
+ if (!(thd->options & OPTION_UPDATE_LOG)
+#ifndef NO_EMBEDDED_ACCESS_CHECKS
+ && (thd->master_access & SUPER_ACL)
+#endif
+ )
{
VOID(pthread_mutex_unlock(&LOCK_log));
return 0;