diff --git a/server/core/config.cc b/server/core/config.cc index 9b982b1f6..6ce381221 100644 --- a/server/core/config.cc +++ b/server/core/config.cc @@ -3188,8 +3188,10 @@ int configure_new_service(CONFIG_CONTEXT *obj) SERVICE *service = (SERVICE*)obj->element; ss_dassert(service); - for (auto&& a: mxs::strtok(config_get_string(obj->parameters, CN_SERVERS), ", \t")) + for (auto&& a: mxs::strtok(config_get_string(obj->parameters, CN_SERVERS), ",")) { + fix_object_name(&a[0]); + if (SERVER* s = server_find_by_unique_name(a.c_str())) { serviceAddBackend(service, s); @@ -3226,8 +3228,9 @@ int create_new_monitor(CONFIG_CONTEXT *obj, std::set& monitored_ser bool err = false; // TODO: Use server list parameter type for this - for (auto&& s: mxs::strtok(config_get_string(obj->parameters, CN_SERVERS), ", \t")) + for (auto&& s: mxs::strtok(config_get_string(obj->parameters, CN_SERVERS), ",")) { + fix_object_name(&s[0]); SERVER* server = server_find_by_unique_name(s.c_str()); if (!server) diff --git a/server/core/monitor.cc b/server/core/monitor.cc index 6957b78dc..aaa796a04 100644 --- a/server/core/monitor.cc +++ b/server/core/monitor.cc @@ -142,8 +142,9 @@ MXS_MONITOR* monitor_create(const char *name, const char *module, MXS_CONFIG_PAR mon->disk_space_check_interval = config_get_integer(params, CN_DISK_SPACE_CHECK_INTERVAL); spinlock_init(&mon->lock); - for (auto&& s: mxs::strtok(config_get_string(params, CN_SERVERS), ", \t")) + for (auto&& s: mxs::strtok(config_get_string(params, CN_SERVERS), ",")) { + fix_object_name(&s[0]); monitor_add_server(mon, server_find_by_unique_name(s.c_str())); } diff --git a/server/core/service.cc b/server/core/service.cc index fe07ecfe7..40f84bad5 100644 --- a/server/core/service.cc +++ b/server/core/service.cc @@ -1129,7 +1129,7 @@ bool service_set_filters(SERVICE* service, const char* filters) std::vector flist; uint64_t capabilities = 0; - for (auto&& f: mxs::strtok(filters, "| \t")) + for (auto&& f: mxs::strtok(filters, "|")) { fix_object_name(&f[0]);