[asterisk-commits] file: branch 1.4 r69847 - in /branches/1.4: ./ res/res_features.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Jun 19 08:00:58 CDT 2007


Author: file
Date: Tue Jun 19 08:00:57 2007
New Revision: 69847

URL: http://svn.digium.com/view/asterisk?view=rev&rev=69847
Log:
Merged revisions 69846 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r69846 | file | 2007-06-19 08:57:55 -0400 (Tue, 19 Jun 2007) | 2 lines

Add parked call extension AFTER the parking slot has been announced, otherwise two threads will try to handle the same channel and it will go kaboom. (issue #9191 reported by japple)

........

Modified:
    branches/1.4/   (props changed)
    branches/1.4/res/res_features.c

Propchange: branches/1.4/
------------------------------------------------------------------------------
Binary property 'branch-1.2-merged' - no diff available.

Modified: branches/1.4/res/res_features.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/res/res_features.c?view=diff&rev=69847&r1=69846&r2=69847
==============================================================================
--- branches/1.4/res/res_features.c (original)
+++ branches/1.4/res/res_features.c Tue Jun 19 08:00:57 2007
@@ -421,13 +421,13 @@
 		con = ast_context_create(NULL, parking_con, registrar);
 	if (!con)	/* Still no context? Bad */
 		ast_log(LOG_ERROR, "Parking context '%s' does not exist and unable to create\n", parking_con);
-	else {		/* Add extension to context */
-		if (!ast_add_extension2(con, 1, pu->parkingexten, 1, NULL, NULL, parkedcall, strdup(pu->parkingexten), ast_free, registrar))
-			notify_metermaids(pu->parkingexten, parking_con);
-	}
 	/* Tell the peer channel the number of the parking space */
 	if (peer && pu->parkingnum != -1) /* Only say number if it's a number */
 		ast_say_digits(peer, pu->parkingnum, "", peer->language);
+	if (con) {
+		if (!ast_add_extension2(con, 1, pu->parkingexten, 1, NULL, NULL, parkedcall, strdup(pu->parkingexten), ast_free, registrar))
+			notify_metermaids(pu->parkingexten, parking_con);
+	}
 	if (pu->notquiteyet) {
 		/* Wake up parking thread if we're really done */
 		ast_indicate_data(pu->chan, AST_CONTROL_HOLD, 




More information about the asterisk-commits mailing list