[asterisk-commits] crichter: branch 1.2 r63519 - /branches/1.2/channels/chan_misdn.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Wed May 9 04:26:16 MST 2007


Author: crichter
Date: Wed May  9 06:26:16 2007
New Revision: 63519

URL: http://svn.digium.com/view/asterisk?view=rev&rev=63519
Log:
release_chan frees ch, so we should never touch ch after release_chan, this may cause segfaults.

Modified:
    branches/1.2/channels/chan_misdn.c

Modified: branches/1.2/channels/chan_misdn.c
URL: http://svn.digium.com/view/asterisk/branches/1.2/channels/chan_misdn.c?view=diff&rev=63519&r1=63518&r2=63519
==============================================================================
--- branches/1.2/channels/chan_misdn.c (original)
+++ branches/1.2/channels/chan_misdn.c Wed May  9 06:26:16 2007
@@ -3999,9 +3999,11 @@
 
 		stop_bc_tones(ch);
 		hangup_chan(ch);
-		release_chan(bc);
+
 		if(ch)	
 			ch->state=MISDN_CLEANING;
+
+		release_chan(bc);
 	}
 	break;
 	case EVENT_BCHAN_ERROR:



More information about the asterisk-commits mailing list