[asterisk-commits] murf: branch 1.6.1 r158572 - in /branches/1.6.1: ./ main/features.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Fri Nov 21 16:57:58 CST 2008


Author: murf
Date: Fri Nov 21 16:57:57 2008
New Revision: 158572

URL: http://svn.digium.com/view/asterisk?view=rev&rev=158572
Log:
Merged revisions 158484 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

................
r158484 | murf | 2008-11-21 14:47:16 -0700 (Fri, 21 Nov 2008) | 19 lines

Merged revisions 158483 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r158483 | murf | 2008-11-21 14:19:47 -0700 (Fri, 21 Nov 2008) | 11 lines

(closes issue #13871)
Reported by: mdu113

This one is totally my fault. The code doesn't even
create a bridge CDR if the channel CDR has POST_DISABLED.
I didn't check for that at the end of the bridge.
Fixed with a few small insertions. Tested. Looks
good. No cdr generated, no crash, no unnecc. data
objects created either.


........

................

Modified:
    branches/1.6.1/   (props changed)
    branches/1.6.1/main/features.c

Propchange: branches/1.6.1/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.

Modified: branches/1.6.1/main/features.c
URL: http://svn.digium.com/view/asterisk/branches/1.6.1/main/features.c?view=diff&rev=158572&r1=158571&r2=158572
==============================================================================
--- branches/1.6.1/main/features.c (original)
+++ branches/1.6.1/main/features.c Fri Nov 21 16:57:57 2008
@@ -2448,13 +2448,15 @@
 	/* obey the NoCDR() wishes. -- move the DISABLED flag to the bridge CDR if it was set on the channel during the bridge... */
 	if (res != AST_PBX_KEEPALIVE) {
 		new_chan_cdr = pick_unlocked_cdr(chan->cdr); /* the proper chan cdr, if there are forked cdrs */
-		if (new_chan_cdr && ast_test_flag(new_chan_cdr, AST_CDR_FLAG_POST_DISABLED))
+		if (bridge_cdr && new_chan_cdr && ast_test_flag(new_chan_cdr, AST_CDR_FLAG_POST_DISABLED))
 			ast_set_flag(bridge_cdr, AST_CDR_FLAG_POST_DISABLED);
 	}
 
 	/* we can post the bridge CDR at this point */
-	ast_cdr_end(bridge_cdr);
-	ast_cdr_detach(bridge_cdr);
+	if (bridge_cdr) {
+		ast_cdr_end(bridge_cdr);
+		ast_cdr_detach(bridge_cdr);
+	}
 	
 	/* do a specialized reset on the beginning channel
 	   CDR's, if they still exist, so as not to mess up




More information about the asterisk-commits mailing list