From 96edaca90c0d5c36999599929962b1aec2ac5bb5 Mon Sep 17 00:00:00 2001 From: Markus Makela Date: Tue, 14 Jul 2015 12:14:01 +0300 Subject: [PATCH] Disabled C99. --- cmake/macros.cmake | 2 +- server/modules/monitor/mysql_mon.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cmake/macros.cmake b/cmake/macros.cmake index 848b3290f..49f4096dc 100644 --- a/cmake/macros.cmake +++ b/cmake/macros.cmake @@ -21,7 +21,7 @@ endmacro() macro(set_variables) # Use C99 - set(USE_C99 TRUE CACHE BOOL "Use C99 standard") + set(USE_C99 FALSE CACHE BOOL "Use C99 standard") # Install the template maxscale.cnf file set(WITH_MAXSCALE_CNF TRUE CACHE BOOL "Install the template maxscale.cnf file") diff --git a/server/modules/monitor/mysql_mon.c b/server/modules/monitor/mysql_mon.c index 8cc78340f..a37526bb5 100644 --- a/server/modules/monitor/mysql_mon.c +++ b/server/modules/monitor/mysql_mon.c @@ -525,7 +525,7 @@ static MONITOR_SERVERS *build_mysql51_replication_tree(MONITOR *mon) { MONITOR_SERVERS* database = mon->databases; MONITOR_SERVERS *ptr,*rval = NULL; - + int i; while(database) { bool ismaster = false; @@ -587,7 +587,7 @@ static MONITOR_SERVERS *build_mysql51_replication_tree(MONITOR *mon) while(ptr) { - for(int i = 0;ptr->server->slaves[i];i++) + for(i = 0;ptr->server->slaves[i];i++) { if(ptr->server->slaves[i] == database->server->node_id) {