Description
There is a race condition happening when a connector is deleted.
On connector delete, the following function is called
void qd_connection_manager_delete_connector(qd_dispatch_t *qd, void *impl) { qd_connector_t *ct = (qd_connector_t*) impl; if (ct) { sys_mutex_lock(ct->lock); if (ct->ctx && ct->ctx->pn_conn) { qd_connection_invoke_deferred(ct->ctx, deferred_close, ct->ctx->pn_conn); } sys_mutex_unlock(ct->lock); DEQ_REMOVE(qd->connection_manager->connectors, ct); qd_connector_decref(ct); } }
The deferred_close() is invoked before qd_connector_decref() is invoked hence the connection's connector is still in place and the connector is re-established.
Attachments
Issue Links
- relates to
-
DISPATCH-870 connection improperly reopened from closed connector
- Closed