summaryrefslogtreecommitdiff
path: root/main/channel.c
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2007-06-07 18:41:17 +0000
committerJoshua Colp <jcolp@digium.com>2007-06-07 18:41:17 +0000
commitef7b38e065b694a1c302dc563e79d09796c95ba8 (patch)
treecbbeb35752af4ac26f115a8bced0fd21f82e8d5e /main/channel.c
parent4b0494f389b67c7c5dbea65a80a975791619554c (diff)
Merged revisions 68157 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r68157 | file | 2007-06-07 14:39:52 -0400 (Thu, 07 Jun 2007) | 2 lines Fix logic when doing a name based channel search for a structure when you want to start from a specific point in the channel list. (issue #9324 reported by slavon) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@68158 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'main/channel.c')
-rw-r--r--main/channel.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/main/channel.c b/main/channel.c
index 64ac4e583..4d329d4c4 100644
--- a/main/channel.c
+++ b/main/channel.c
@@ -950,6 +950,11 @@ static struct ast_channel *channel_find_locked(const struct ast_channel *prev,
* want to return NULL, instead of trying to deref NULL in the
* next section.
*/
+ prev = NULL;
+ /* We want prev to be NULL in case we end up doing more searching through
+ * the channel list to find the channel (ie: name searching). If we didn't
+ * set this to NULL the logic would just blow up
+ */
}
if (name) { /* want match by name */
if ((!namelen && strcasecmp(c->name, name)) ||