Merged revisions 53532 via svnmerge from
authorTilghman Lesher <tilghman@meg.abyt.es>
Thu, 8 Feb 2007 13:50:33 +0000 (13:50 +0000)
committerTilghman Lesher <tilghman@meg.abyt.es>
Thu, 8 Feb 2007 13:50:33 +0000 (13:50 +0000)
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r53532 | tilghman | 2007-02-08 07:47:54 -0600 (Thu, 08 Feb 2007) | 2 lines

Issue 9007 - Mutex not released on early return

........

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@53533 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/loader.c

index 525eef4..65c95ec 100644 (file)
@@ -536,8 +536,10 @@ int ast_module_reload(const char *name)
        }
        ast_lastreloadtime = time(NULL);
 
-       if (name && res)
+       if (name && res) {
+               ast_mutex_unlock(&reloadlock);
                return res;
+       }
 
        AST_LIST_LOCK(&module_list);
        AST_LIST_TRAVERSE(&module_list, cur, entry) {