MXS-2584: Assert that workers are initialized
The initialization must always be done before a call to RoutingWorker::get is done.
This commit is contained in:
@ -446,6 +446,8 @@ bool mxs_worker_should_shutdown(MXB_WORKER* pWorker)
|
|||||||
|
|
||||||
RoutingWorker* RoutingWorker::get(int worker_id)
|
RoutingWorker* RoutingWorker::get(int worker_id)
|
||||||
{
|
{
|
||||||
|
mxb_assert(this_unit.initialized);
|
||||||
|
|
||||||
if (worker_id == MAIN)
|
if (worker_id == MAIN)
|
||||||
{
|
{
|
||||||
worker_id = this_unit.id_main_worker;
|
worker_id = this_unit.id_main_worker;
|
||||||
|
Reference in New Issue
Block a user