mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 15:45:18 +00:00
sorcery: Add ast_sorcery_object_unregister() API call.
Find and unlink the specified sorcery object type to complement ast_sorcery_object_register(). Without this function you cannot completely unload individual modules that use sorcery for configuration. ASTERISK-24907 Reported by: Kevin Harwell Change-Id: I1c04634fe9a90921bf676725c7d6bb2aeaab1c88
This commit is contained in:
@@ -616,6 +616,17 @@ int ast_sorcery_get_wizard_mapping_count(struct ast_sorcery *sorcery,
|
||||
int ast_sorcery_get_wizard_mapping(struct ast_sorcery *sorcery,
|
||||
const char *type, int index, struct ast_sorcery_wizard **wizard, void **data);
|
||||
|
||||
/*!
|
||||
* \brief Unregister an object type
|
||||
*
|
||||
* \param sorcery Pointer to a sorcery structure
|
||||
* \param type Type of object
|
||||
*
|
||||
* \retval 0 success
|
||||
* \retval -1 failure
|
||||
*/
|
||||
int ast_sorcery_object_unregister(struct ast_sorcery *sorcery, const char *type);
|
||||
|
||||
/*!
|
||||
* \brief Register an object type
|
||||
*
|
||||
|
Reference in New Issue
Block a user