MXS-1929: Fix binlogrouter unit test failure

The test failed because router instances are now created when the service
is allocated. In addition to this, a debug assertion was hit when a
service was freed if the router instance creation failed.
This commit is contained in:
Markus Mäkelä
2018-07-18 16:42:08 +03:00
parent 146fe76c7a
commit f10eab4406
2 changed files with 27 additions and 14 deletions

View File

@ -165,6 +165,7 @@ SERVICE* service_alloc(const char *name, const char *router, MXS_CONFIG_PARAMETE
if (service->router_instance == NULL)
{
MXS_ERROR("%s: Failed to create router instance. Service not started.", service->name);
service->active = false;
service_free(service);
return NULL;
}