[asterisk-commits] may: branch 1.8 r346762 - in /branches/1.8: addons/ channels/

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Dec 2 10:19:23 CST 2011


Author: may
Date: Fri Dec  2 10:19:19 2011
New Revision: 346762

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=346762
Log:
process null frame pointer returned by ast_rtp_instance_read correctly

(closes issue ASTERISK-16697)
Reported by: under
Patches: 
        segfault.diff (License #5871) patch uploaded by under

Modified:
    branches/1.8/addons/chan_ooh323.c
    branches/1.8/channels/chan_h323.c

Modified: branches/1.8/addons/chan_ooh323.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.8/addons/chan_ooh323.c?view=diff&rev=346762&r1=346761&r2=346762
==============================================================================
--- branches/1.8/addons/chan_ooh323.c (original)
+++ branches/1.8/addons/chan_ooh323.c Fri Dec  2 10:19:19 2011
@@ -4286,7 +4286,7 @@
 		f = &null_frame;
 	}
 
-	if (p->owner) {
+	if (f && p->owner) {
 		/* We already hold the channel lock */
 		if (f->frametype == AST_FRAME_VOICE && !p->faxmode) {
 			if (f->subclass.codec != p->owner->nativeformats) {

Modified: branches/1.8/channels/chan_h323.c
URL: http://svnview.digium.com/svn/asterisk/branches/1.8/channels/chan_h323.c?view=diff&rev=346762&r1=346761&r2=346762
==============================================================================
--- branches/1.8/channels/chan_h323.c (original)
+++ branches/1.8/channels/chan_h323.c Fri Dec  2 10:19:19 2011
@@ -764,7 +764,7 @@
 	if (f && (f->frametype == AST_FRAME_DTMF) && !(pvt->options.dtmfmode & (H323_DTMF_RFC2833 | H323_DTMF_CISCO))) {
 		return &ast_null_frame;
 	}
-	if (pvt->owner) {
+	if (f && pvt->owner) {
 		/* We already hold the channel lock */
 		if (f->frametype == AST_FRAME_VOICE) {
 			if (f->subclass.codec != pvt->owner->nativeformats) {




More information about the asterisk-commits mailing list