[asterisk-commits] mmichelson: trunk r249105 - /trunk/main/features.c
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Feb 26 11:13:40 CST 2010
Author: mmichelson
Date: Fri Feb 26 11:13:36 2010
New Revision: 249105
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=249105
Log:
Send a manager event when the manager BridgeAction command is used.
(closes issue #16769)
Reported by: syspert
Patches:
bridgeaction.patch uploaded by syspert (license 938)
Modified:
trunk/main/features.c
Modified: trunk/main/features.c
URL: http://svnview.digium.com/svn/asterisk/trunk/main/features.c?view=diff&rev=249105&r1=249104&r2=249105
==============================================================================
--- trunk/main/features.c (original)
+++ trunk/main/features.c Fri Feb 26 11:13:36 2010
@@ -4534,7 +4534,7 @@
const char *channela = astman_get_header(m, "Channel1");
const char *channelb = astman_get_header(m, "Channel2");
const char *playtone = astman_get_header(m, "Tone");
- struct ast_channel *chana = NULL, *chanb = NULL;
+ struct ast_channel *chana = NULL, *chanb = NULL, *chans[2];
struct ast_channel *tmpchana = NULL, *tmpchanb = NULL;
struct ast_bridge_thread_obj *tobj = NULL;
@@ -4627,6 +4627,14 @@
ast_log(LOG_WARNING, "Failed to play a courtesy tone on chan %s\n", tmpchanb->name);
}
}
+
+ chans[0] = tmpchana;
+ chans[1] = tmpchanb;
+
+ ast_manager_event_multichan(EVENT_FLAG_CALL, "BridgeAction", 2, chans,
+ "Response: Success\r\n"
+ "Channel1: %s\r\n"
+ "Channel2: %s\r\n", tmpchana->name, tmpchanb->name);
bridge_call_thread_launch(tobj);
More information about the asterisk-commits
mailing list