summaryrefslogtreecommitdiff
path: root/storage
diff options
context:
space:
mode:
authorSergei Golubchik <serg@mariadb.org>2018-09-22 15:19:40 +0200
committerSergei Golubchik <serg@mariadb.org>2018-09-22 15:19:40 +0200
commit3a9276bad31810a87133dd003bbe345602627ecc (patch)
tree9940be020713007c28cf0938b4041bfce903b6f5 /storage
parenta4131c51f55bf0c0ee7bf5a72d877d2ecc46872e (diff)
downloadmariadb-git-3a9276bad31810a87133dd003bbe345602627ecc.tar.gz
sanitize tokudb locking macros
Diffstat (limited to 'storage')
-rw-r--r--storage/tokudb/hatoku_defines.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/storage/tokudb/hatoku_defines.h b/storage/tokudb/hatoku_defines.h
index 66a8fa5d982..2fd149d120d 100644
--- a/storage/tokudb/hatoku_defines.h
+++ b/storage/tokudb/hatoku_defines.h
@@ -290,23 +290,23 @@ inline uint tokudb_uint3korr(const uchar *a) {
typedef unsigned int pfs_key_t;
#if defined(SAFE_MUTEX) || defined(HAVE_PSI_MUTEX_INTERFACE)
-#define mutex_t_lock(M) M.lock(__FILE__, __LINE__)
+#define mutex_t_lock(M) (M).lock(__FILE__, __LINE__)
#else // SAFE_MUTEX || HAVE_PSI_MUTEX_INTERFACE
-#define mutex_t_lock(M) M.lock()
+#define mutex_t_lock(M) (M).lock()
#endif // SAFE_MUTEX || HAVE_PSI_MUTEX_INTERFACE
#if defined(SAFE_MUTEX)
-#define mutex_t_unlock(M) M.unlock(__FILE__, __LINE__)
+#define mutex_t_unlock(M) (M).unlock(__FILE__, __LINE__)
#else // SAFE_MUTEX
-#define mutex_t_unlock(M) M.unlock()
+#define mutex_t_unlock(M) (M).unlock()
#endif // SAFE_MUTEX
#if defined(HAVE_PSI_RWLOCK_INTERFACE)
-#define rwlock_t_lock_read(M) M.lock_read(__FILE__, __LINE__)
-#define rwlock_t_lock_write(M) M.lock_write(__FILE__, __LINE__)
+#define rwlock_t_lock_read(M) (M).lock_read(__FILE__, __LINE__)
+#define rwlock_t_lock_write(M) (M).lock_write(__FILE__, __LINE__)
#else // HAVE_PSI_RWLOCK_INTERFACE
-#define rwlock_t_lock_read(M) M.lock_read()
-#define rwlock_t_lock_write(M) M.lock_write()
+#define rwlock_t_lock_read(M) (M).lock_read()
+#define rwlock_t_lock_write(M) (M).lock_write()
#endif // HAVE_PSI_RWLOCK_INTERFACE
#endif // _HATOKU_DEFINES_H