[asterisk-commits] mmichelson: trunk r169211 - in /trunk: ./ channels/chan_local.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Jan 19 09:54:06 CST 2009
Author: mmichelson
Date: Mon Jan 19 09:54:06 2009
New Revision: 169211
URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=169211
Log:
Merged revisions 169210 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r169210 | mmichelson | 2009-01-19 09:52:15 -0600 (Mon, 19 Jan 2009) | 13 lines
Prevent a crash in chan_local due to a potential NULL pointer dereference
Move the check for if both channels on a local_pvt have generators to below
where p->chan is checked for NULLity (NULLness?). This prevents a crash from
occurring if p->chan is NULL.
(closes issue #14189)
Reported by: sascha
Patches:
14189.patch uploaded by putnopvut (license 60)
Tested by: sascha
........
Modified:
trunk/ (props changed)
trunk/channels/chan_local.c
Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.
Modified: trunk/channels/chan_local.c
URL: http://svn.digium.com/svn-view/asterisk/trunk/channels/chan_local.c?view=diff&rev=169211&r1=169210&r2=169211
==============================================================================
--- trunk/channels/chan_local.c (original)
+++ trunk/channels/chan_local.c Mon Jan 19 09:54:06 2009
@@ -203,10 +203,6 @@
/* Recalculate outbound channel */
other = isoutbound ? p->owner : p->chan;
- /* do not queue frame if generator is on both local channels */
- if (us && us->generator && other->generator)
- return 0;
-
/* Set glare detection */
ast_set_flag(p, LOCAL_GLARE_DETECT);
if (ast_test_flag(p, LOCAL_CANCEL_QUEUE)) {
@@ -220,6 +216,10 @@
ast_clear_flag(p, LOCAL_GLARE_DETECT);
return 0;
}
+
+ /* do not queue frame if generator is on both local channels */
+ if (us && us->generator && other->generator)
+ return 0;
/* Ensure that we have both channels locked */
while (other && ast_channel_trylock(other)) {
More information about the asterisk-commits
mailing list