summaryrefslogtreecommitdiff
path: root/sql/sql_class.h
diff options
context:
space:
mode:
Diffstat (limited to 'sql/sql_class.h')
-rw-r--r--sql/sql_class.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/sql/sql_class.h b/sql/sql_class.h
index bd295be101c..46c37e1b57f 100644
--- a/sql/sql_class.h
+++ b/sql/sql_class.h
@@ -299,9 +299,14 @@ public:
}
inline bool active_transaction()
{
+#ifdef USING_TRANSACTIONS
return (transaction.all.bdb_tid != 0 ||
transaction.all.innobase_tid != 0 ||
transaction.all.gemini_tid != 0);
+#else
+ return 0;
+#endif
+
}
inline gptr alloc(unsigned int size) { return alloc_root(&mem_root,size); }
inline gptr calloc(unsigned int size)