]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Allow dialing local channels from Queue() and Dial() again. There was a slight
authorRussell Bryant <russell@russellbryant.com>
Fri, 7 Dec 2007 02:38:40 +0000 (02:38 +0000)
committerRussell Bryant <russell@russellbryant.com>
Fri, 7 Dec 2007 02:38:40 +0000 (02:38 +0000)
flaw in the code to prevent call forwards from looping that caused this problem.
(related to issue #11486)

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

apps/app_dial.c
apps/app_queue.c

index cc9722e93c1e4c383532659bb2909a1a79da5a6b..b89f52097423bbb331b8658767d4144a34d17ee0 100644 (file)
@@ -1159,7 +1159,7 @@ static int dial_exec_full(struct ast_channel *chan, void *data, struct ast_flags
                        }
                        strcpy(di->interface, interface);
                        AST_LIST_INSERT_TAIL(dialed_interfaces, di, list);
-               } else {
+               } else if (dialed) {
                        AST_LIST_UNLOCK(dialed_interfaces);
                        ast_log(LOG_WARNING, "Skipping dialing interface '%s' again since it has already been dialed\n", di->interface);
                        fulldial++;
index 8868e9c5702414093baa73f1494418bf14342d55..8606ede2fb19d4a306ab56dc7fdb88f858248287 100644 (file)
@@ -2604,9 +2604,8 @@ static int try_calling(struct queue_ent *qe, const char *options, char *announce
                        }
                        strcpy(di->interface, cur->interface);
                        AST_LIST_INSERT_TAIL(dialed_interfaces, di, list);
-               } else {
-                       if (di)
-                               ast_log(LOG_DEBUG, "Skipping dialing interface '%s' since it has already been dialed\n", di->interface);
+               } else if (dialed) {
+                       ast_log(LOG_DEBUG, "Skipping dialing interface '%s' since it has already been dialed\n", di->interface);
                        AST_LIST_UNLOCK(dialed_interfaces);
                        free(tmp);
                        continue;