void hub_shutdown_service(struct hub_info* hub) { LOG_DEBUG("hub_shutdown_service()"); if (net_backend_get_timeout_queue()) { timeout_queue_remove(net_backend_get_timeout_queue(), hub->stats.timeout); hub_free(hub->stats.timeout); } #ifdef SSL_SUPPORT unload_ssl_certificates(hub); #endif event_queue_shutdown(hub->queue); net_con_close(hub->server); server_alt_port_stop(hub); uman_shutdown(hub->users); list_clear(hub->muxes, &hub_mux_destroy); list_destroy(hub->muxes); hub->status = hub_status_stopped; hub_free(hub->sendbuf); hub_free(hub->recvbuf); list_clear(hub->logout_info, &hub_free); list_destroy(hub->logout_info); command_shutdown(hub->commands); hub_free(hub); hub = 0; g_hub = 0; }
void hub_shutdown_service(struct hub_info* hub) { LOG_DEBUG("hub_shutdown_service()"); #ifdef SSL_SUPPORT unload_ssl_certificates(hub); #endif event_queue_shutdown(hub->queue); net_con_close(hub->server); hub_free(hub->server); server_alt_port_stop(hub); uman_shutdown(hub); hub->status = hub_status_stopped; hub_free(hub->sendbuf); hub_free(hub->recvbuf); hub_chat_history_clear(hub); list_destroy(hub->chat_history); list_clear(hub->logout_info, &hub_free); list_destroy(hub->logout_info); hub_free(hub); hub = 0; g_hub = 0; }