Skip to content
Snippets Groups Projects
Commit 09d8972b authored by Anthony LaMantia's avatar Anthony LaMantia
Browse files

small fix for 7944

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@42891 65c4cc65-6c06-0410-ace0-fbb531ad65f3
parent 25b0e3a1
No related branches found
No related tags found
No related merge requests found
......@@ -199,6 +199,17 @@ struct ast_module_user *__ast_module_user_add(struct ast_module *mod,
void __ast_module_user_remove(struct ast_module *mod, struct ast_module_user *u)
{
if (u <= 0) {
ast_log(LOG_ERROR,"ast_module_user invalid can not remove \n");
return;
}
if (mod <= 0) {
ast_log(LOG_ERROR,"ast_module invalid can not remove \n");
return;
}
AST_LIST_LOCK(&mod->users);
AST_LIST_REMOVE(&mod->users, u, entry);
AST_LIST_UNLOCK(&mod->users);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment