diff --git a/CMakeLists.txt b/CMakeLists.txt index 4627a3e43..9bae1af40 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -184,13 +184,13 @@ execute_process(COMMAND perl ${CMAKE_SOURCE_DIR}/Documentation/format.pl ${CMAKE_SOURCE_DIR}/Documentation/Release-Notes/MaxScale-1.2.0-Release-Notes.md ${CMAKE_BINARY_DIR}/ReleaseNotes.txt) execute_process(COMMAND perl ${CMAKE_SOURCE_DIR}/Documentation/format.pl -${CMAKE_SOURCE_DIR}/Documentation/Upgrading/Upgrading-To-MaxScale-1.2.0.md - ${CMAKE_BINARY_DIR}/UpgradingToMaxScale120.txt) +${CMAKE_SOURCE_DIR}/Documentation/Upgrading/Upgrading-To-MaxScale-1.2.md + ${CMAKE_BINARY_DIR}/UpgradingToMaxScale12.txt) install(FILES ${CMAKE_BINARY_DIR}/Changelog.txt DESTINATION ${MAXSCALE_SHAREDIR}) install(FILES ${CMAKE_BINARY_DIR}/ReleaseNotes.txt DESTINATION ${MAXSCALE_SHAREDIR}) -install(FILES ${CMAKE_BINARY_DIR}/UpgradingToMaxScale120.txt DESTINATION ${MAXSCALE_SHAREDIR}) +install(FILES ${CMAKE_BINARY_DIR}/UpgradingToMaxScale12.txt DESTINATION ${MAXSCALE_SHAREDIR}) install(FILES server/maxscale_template.cnf DESTINATION ${MAXSCALE_SHAREDIR}) if(WITH_MAXSCALE_CNF) install(FILES server/maxscale_template.cnf DESTINATION ${MAXSCALE_CONFDIR} RENAME maxscale.cnf.template) @@ -262,7 +262,11 @@ if(PACKAGE) set(CPACK_PACKAGE_VERSION_MINOR "${MAXSCALE_VERSION_MINOR}") set(CPACK_PACKAGE_VERSION_PATCH "${MAXSCALE_VERSION_PATCH}") set(CPACK_PACKAGE_CONTACT "MariaDB Corporation Ab") - set(CPACK_PACKAGE_FILE_NAME "maxscale-${MAXSCALE_VERSION}-${CPACK_PACKAGE_ARCHITECTURE}-${DISTRIB_SUFFIX}") + if(DISTRIB_SUFFIX) + set(CPACK_PACKAGE_FILE_NAME "maxscale-${MAXSCALE_VERSION}-${MAXSCALE_BUILD_NUMBER}.${DISTRIB_SUFFIX}.${CPACK_PACKAGE_ARCHITECTURE}") + else() + set(CPACK_PACKAGE_FILE_NAME "maxscale-${MAXSCALE_VERSION}-${MAXSCALE_BUILD_NUMBER}.${CPACK_PACKAGE_ARCHITECTURE}") + endif() set(CPACK_PACKAGE_NAME "maxscale") set(CPACK_PACKAGE_VENDOR "MariaDB Corporation Ab") set(CPACK_PACKAGE_DESCRIPTION_FILE ${CMAKE_SOURCE_DIR}/etc/DESCRIPTION) diff --git a/Documentation/Documentation-Contents.md b/Documentation/Documentation-Contents.md index ddfd54ba4..14248e222 100644 --- a/Documentation/Documentation-Contents.md +++ b/Documentation/Documentation-Contents.md @@ -20,7 +20,7 @@ ## Upgrading MaxScale -- [Upgrading MaxScale from 1.1.1 to 1.2.0](Upgrading/Upgrading-To-MaxScale-1.2.0.md) +- [Upgrading MaxScale from 1.1.1 to 1.2](Upgrading/Upgrading-To-MaxScale-1.2.md) - [Upgrading MaxScale from 1.0.5 to 1.1.0](Upgrading/Upgrading-To-MaxScale-1.1.0.md) ## Reference diff --git a/Documentation/Upgrading/Upgrading-To-MaxScale-1.2.0.md b/Documentation/Upgrading/Upgrading-To-MaxScale-1.2.md similarity index 100% rename from Documentation/Upgrading/Upgrading-To-MaxScale-1.2.0.md rename to Documentation/Upgrading/Upgrading-To-MaxScale-1.2.md diff --git a/etc/postrm.in b/etc/postrm.in index 7488ebe46..239715448 100755 --- a/etc/postrm.in +++ b/etc/postrm.in @@ -6,7 +6,7 @@ then rm -f /usr/lib/systemd/system/maxscale.service else # Copy and rename config from old location - if [ -f "/usr/local/mariadb-maxscale/etc/MaxScale.cnf" ] + if [ -f "/usr/local/mariadb-maxscale/etc/MaxScale.cnf" -a ! -f "/etc/maxscale.cnf" ] then cp "/usr/local/mariadb-maxscale/etc/MaxScale.cnf" "/etc/maxscale.cnf" fi diff --git a/server/core/gateway.c b/server/core/gateway.c index 0907d6365..f0744cfd1 100644 --- a/server/core/gateway.c +++ b/server/core/gateway.c @@ -1670,7 +1670,7 @@ int main(int argc, char **argv) if(!daemon_mode) { strncat(errorbuffer, "\n", STRING_BUFFER_SIZE); - fprintf(stderr, errorbuffer); + fprintf(stderr, "%s", errorbuffer); } rc = MAXSCALE_BADCONFIG; diff --git a/server/core/test/testmemlog.c b/server/core/test/testmemlog.c index 1523ec8ec..d1cad08ae 100644 --- a/server/core/test/testmemlog.c +++ b/server/core/test/testmemlog.c @@ -67,7 +67,7 @@ int main() { MEMLOG *log, *log2; -int i; +long int i; long j; long long k; int failures = 0; diff --git a/server/core/test/testspinlock.c b/server/core/test/testspinlock.c index 14501cea5..ed8fa7214 100644 --- a/server/core/test/testspinlock.c +++ b/server/core/test/testspinlock.c @@ -151,11 +151,14 @@ test3_helper(void *data) // SPINLOCK *lck = (SPINLOCK *)data; int i; int n = *(int *)data; -struct timespec sleeptime; time_t rawtime; +#if defined(ADD_SOME_NANOSLEEP) +struct timespec sleeptime; + sleeptime.tv_sec = 0; sleeptime.tv_nsec = 1; +#endif while (1) { if (spinlock_acquire_nowait(&lck)) { @@ -185,7 +188,9 @@ time_t rawtime; active = 0; spinlock_release(&lck); for (i=0; i<(4*PROCESS_LOOP); i++); - // nanosleep(&sleeptime, NULL); +#if defined(ADD_SOME_NANOSLEEP) + nanosleep(&sleeptime, NULL); +#endif } spinlock_release(&lck); } @@ -199,11 +204,6 @@ int i; int tnum[THREADS]; time_t rawtime; -struct timespec sleeptime; - - sleeptime.tv_sec = 20; - sleeptime.tv_nsec = NANOTIME; - times_run = 0; active = 0; failures = 0; diff --git a/server/modules/protocol/mysql_client.c b/server/modules/protocol/mysql_client.c index 6552187a5..1056d1bed 100644 --- a/server/modules/protocol/mysql_client.c +++ b/server/modules/protocol/mysql_client.c @@ -1808,8 +1808,8 @@ static int gw_error_client_event( } #if defined(SS_DEBUG) - LOGIF(LE, (skygw_log_write_flush( - LOGFILE_ERROR, + LOGIF(LD, (skygw_log_write_flush( + LOGFILE_DEBUG, "Client error event handling."))); #endif dcb_close(dcb); @@ -1897,8 +1897,8 @@ gw_client_hangup_event(DCB *dcb) goto retblock; } #if defined(SS_DEBUG) - LOGIF(LE, (skygw_log_write_flush( - LOGFILE_ERROR, + LOGIF(LD, (skygw_log_write_flush( + LOGFILE_DEBUG, "Client hangup error handling."))); #endif dcb_close(dcb); diff --git a/server/modules/protocol/mysql_common.c b/server/modules/protocol/mysql_common.c index b3dfc37be..354820d4a 100644 --- a/server/modules/protocol/mysql_common.c +++ b/server/modules/protocol/mysql_common.c @@ -2261,7 +2261,7 @@ char *create_auth_fail_str( } else if(errcode == MYSQL_FAILED_AUTH_SSL) { - sprintf(errstr, ferrstr); + sprintf(errstr, "%s", ferrstr); } else {