]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Remove unnecessary (but unexecutable) unlocks, cleanup code (bug #6220)
authorMark Spencer <markster@digium.com>
Thu, 12 Jan 2006 17:34:10 +0000 (17:34 +0000)
committerMark Spencer <markster@digium.com>
Thu, 12 Jan 2006 17:34:10 +0000 (17:34 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@8017 65c4cc65-6c06-0410-ace0-fbb531ad65f3

pbx.c

diff --git a/pbx.c b/pbx.c
index 8c12d556e2a096145ed76495082bc6eb1fafc083..a70f922fca462c436563a6f2d647863bd317ec25 100644 (file)
--- a/pbx.c
+++ b/pbx.c
@@ -5058,7 +5058,7 @@ void __ast_context_destroy(struct ast_context *con, const char *registrar)
                           is searching through it. */
                        if (ast_mutex_lock(&tmp->lock)) {
                                ast_log(LOG_WARNING, "Unable to lock context lock\n");
-                               return;
+                               break;
                        }
                        if (tmpl)
                                tmpl->next = tmp->next;
@@ -5105,8 +5105,7 @@ void __ast_context_destroy(struct ast_context *con, const char *registrar)
                                tmpil = NULL;
                                continue;
                        }
-                       ast_mutex_unlock(&conlock);
-                       return;
+                       break;
                }
                tmpl = tmp;
                tmp = tmp->next;