From c1a70084798746b5856735bdd39403779341c9ce Mon Sep 17 00:00:00 2001 From: Johan Wikman Date: Wed, 27 Sep 2017 12:33:50 +0300 Subject: [PATCH] MXS-1449 Sort case statements Faster to later check for something specific. --- server/modules/filter/dbfwfilter/dbfwfilter.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/server/modules/filter/dbfwfilter/dbfwfilter.c b/server/modules/filter/dbfwfilter/dbfwfilter.c index 274b7a834..5625e25f3 100644 --- a/server/modules/filter/dbfwfilter/dbfwfilter.c +++ b/server/modules/filter/dbfwfilter/dbfwfilter.c @@ -2308,13 +2308,13 @@ static bool command_is_mandatory(const GWBUF *buffer) { switch (MYSQL_GET_COMMAND((uint8_t*)GWBUF_DATA(buffer))) { - case MYSQL_COM_QUIT: - case MYSQL_COM_PING: case MYSQL_COM_CHANGE_USER: - case MYSQL_COM_SET_OPTION: case MYSQL_COM_FIELD_LIST: - case MYSQL_COM_PROCESS_KILL: + case MYSQL_COM_PING: case MYSQL_COM_PROCESS_INFO: + case MYSQL_COM_PROCESS_KILL: + case MYSQL_COM_QUIT: + case MYSQL_COM_SET_OPTION: return true; default: