From 03e06727e8bb55019759bcba6177de1a6a04976d Mon Sep 17 00:00:00 2001 From: Markus Makela Date: Wed, 7 Dec 2016 10:58:01 +0200 Subject: [PATCH] Fix order of function declarations in session.h A function was used before it was declared. --- include/maxscale/session.h | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/include/maxscale/session.h b/include/maxscale/session.h index 8e44f02de..77ab61b89 100644 --- a/include/maxscale/session.h +++ b/include/maxscale/session.h @@ -260,21 +260,6 @@ session_trx_state_t session_get_trx_state(const SESSION* ses); */ session_trx_state_t session_set_trx_state(SESSION* ses, session_trx_state_t new_state); -/** - * Tells whether a transaction is active. - * - * @see session_get_trx_state - * - * @note The return value is valid only if either a router or a filter - * has declared that it needs RCAP_TYPE_TRANSACTION_TRACKING. - * - * @return True if a transaction is active, false otherwise. - */ -static inline bool session_trx_is_active(const SESSION* ses) -{ - return !session_is_autocommit(ses) || (ses->trx_state & SESSION_TRX_ACTIVE_BIT); -} - /** * Tells whether an explicit READ ONLY transaction is active. * @@ -329,6 +314,21 @@ static inline bool session_is_autocommit(const SESSION* ses) return ses->autocommit; } +/** + * Tells whether a transaction is active. + * + * @see session_get_trx_state + * + * @note The return value is valid only if either a router or a filter + * has declared that it needs RCAP_TYPE_TRANSACTION_TRACKING. + * + * @return True if a transaction is active, false otherwise. + */ +static inline bool session_trx_is_active(const SESSION* ses) +{ + return !session_is_autocommit(ses) || (ses->trx_state & SESSION_TRX_ACTIVE_BIT); +} + /** * Sets the autocommit state of the session. *