summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mysys/my_thr_init.c4
-rw-r--r--storage/maria/ma_loghandler.c4
2 files changed, 5 insertions, 3 deletions
diff --git a/mysys/my_thr_init.c b/mysys/my_thr_init.c
index da61d32d35c..bdf998f4c10 100644
--- a/mysys/my_thr_init.c
+++ b/mysys/my_thr_init.c
@@ -385,6 +385,8 @@ struct st_my_thread_var *_my_thread_var(void)
return tmp;
}
+#ifndef DBUG_OFF
+
extern void *my_thread_var_get_dbug(my_bool *error)
{
struct st_my_thread_var *tmp=
@@ -406,7 +408,7 @@ extern void my_thread_var_set_dbug(void *dbug)
struct st_my_thread_var *tmp= _my_thread_var();
tmp->dbug= dbug;
}
-
+#endif
/****************************************************************************
Get name of current thread.
diff --git a/storage/maria/ma_loghandler.c b/storage/maria/ma_loghandler.c
index d68bcc7b393..1b6ea3ca923 100644
--- a/storage/maria/ma_loghandler.c
+++ b/storage/maria/ma_loghandler.c
@@ -1262,7 +1262,7 @@ static my_bool translog_buffer_lock(struct st_translog_buffer *buffer)
}
#else
#define translog_buffer_lock(B) \
- pthread_mutex_lock(&B->mutex)
+ pthread_mutex_lock(&((B)->mutex))
#endif
@@ -1296,7 +1296,7 @@ static my_bool translog_buffer_unlock(struct st_translog_buffer *buffer)
}
#else
#define translog_buffer_unlock(B) \
- pthread_mutex_unlock(&B->mutex)
+ pthread_mutex_unlock(&((B)->mutex))
#endif