[svn-commits] tilghman: trunk r56686 - in /trunk: ./ main/channel.c
svn-commits at lists.digium.com
svn-commits at lists.digium.com
Sun Feb 25 07:53:41 MST 2007
Author: tilghman
Date: Sun Feb 25 08:53:40 2007
New Revision: 56686
URL: http://svn.digium.com/view/asterisk?view=rev&rev=56686
Log:
Merged revisions 56685 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
................
r56685 | tilghman | 2007-02-25 08:46:41 -0600 (Sun, 25 Feb 2007) | 11 lines
Merged revisions 56684 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.2
........
r56684 | tilghman | 2007-02-25 08:38:03 -0600 (Sun, 25 Feb 2007) | 3 lines
Issue 9130 - If prev is the last item on the channel list, then evaluating
additional conditions (e.g. name prefix) will cause a NULL dereference.
........
................
Modified:
trunk/ (props changed)
trunk/main/channel.c
Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.
Modified: trunk/main/channel.c
URL: http://svn.digium.com/view/asterisk/trunk/main/channel.c?view=diff&rev=56686&r1=56685&r2=56686
==============================================================================
--- trunk/main/channel.c (original)
+++ trunk/main/channel.c Sun Feb 25 08:53:40 2007
@@ -906,7 +906,11 @@
if (c != prev) /* not this one */
continue;
/* found, prepare to return c->next */
- c = AST_LIST_NEXT(c, chan_list);
+ if ((c = AST_LIST_NEXT(c, chan_list)) == NULL) break;
+ /* If prev was the last item on the channel list, then we just
+ * want to return NULL, instead of trying to deref NULL in the
+ * next section.
+ */
}
if (name) { /* want match by name */
if ((!namelen && strcasecmp(c->name, name)) ||
More information about the svn-commits
mailing list