if (!(io = io_context_create())) {
ast_log(LOG_ERROR, "Unable to create I/O context\n");
- ast_sched_context_destroy(sched);
return AST_MODULE_LOAD_FAILURE;
}
can_parse_xml = sip_is_xml_parsable();
if (reload_config(sip_reloadreason)) { /* Load the configuration from sip.conf */
+ ast_sip_api_provider_unregister();
return AST_MODULE_LOAD_DECLINE;
}
initialize_escs();
if (sip_epa_register(&cc_epa_static_data)) {
+ ast_sip_api_provider_unregister();
return AST_MODULE_LOAD_DECLINE;
}
if (sip_reqresp_parser_init() == -1) {
ast_log(LOG_ERROR, "Unable to initialize the SIP request and response parser\n");
+ ast_sip_api_provider_unregister();
return AST_MODULE_LOAD_DECLINE;
}
* in incoming PUBLISH requests
*/
if (ast_cc_agent_register(&sip_cc_agent_callbacks)) {
+ ast_sip_api_provider_unregister();
return AST_MODULE_LOAD_DECLINE;
}
}
if (ast_cc_monitor_register(&sip_cc_monitor_callbacks)) {
+ ast_sip_api_provider_unregister();
return AST_MODULE_LOAD_DECLINE;
}
if (!(sip_monitor_instances = ao2_container_alloc(37, sip_monitor_instance_hash_fn, sip_monitor_instance_cmp_fn))) {
+ ast_sip_api_provider_unregister();
return AST_MODULE_LOAD_DECLINE;
}