[svn-commits] tilghman: branch 1.4 r46078 - /branches/1.4/main/channel.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Mon Oct 23 20:01:01 MST 2006


Author: tilghman
Date: Mon Oct 23 22:01:00 2006
New Revision: 46078

URL: http://svn.digium.com/view/asterisk?rev=46078&view=rev
Log:
Pass through a frame if we don't know what it is, rather than trying to pass a
NULL, which will segfault a channel driver (Bug 8149)

Modified:
    branches/1.4/main/channel.c

Modified: branches/1.4/main/channel.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/channel.c?rev=46078&r1=46077&r2=46078&view=diff
==============================================================================
--- branches/1.4/main/channel.c (original)
+++ branches/1.4/main/channel.c Mon Oct 23 22:01:00 2006
@@ -2611,7 +2611,10 @@
 		res = 0;
 		break;
 	default:
-		res = chan->tech->write(chan, f);
+		/* At this point, fr is the incoming frame and f is NULL.  Channels do
+		 * not expect to get NULL as a frame pointer and will segfault.  Hence,
+		 * we output the original frame passed in. */
+		res = chan->tech->write(chan, fr);
 		break;
 	}
 



More information about the svn-commits mailing list