[asterisk-commits] mmichelson: branch group/ari-greedy-atxfer r419687 - in /team/group/ari-greed...

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Mon Jul 28 13:54:45 CDT 2014


Author: mmichelson
Date: Mon Jul 28 13:54:43 2014
New Revision: 419687

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=419687
Log:
Back out revision 419683 because it is the incorrect revision of the code I intended to commit.


Modified:
    team/group/ari-greedy-atxfer/include/asterisk/bridge_channel.h
    team/group/ari-greedy-atxfer/res/stasis/stasis_bridge.c

Modified: team/group/ari-greedy-atxfer/include/asterisk/bridge_channel.h
URL: http://svnview.digium.com/svn/asterisk/team/group/ari-greedy-atxfer/include/asterisk/bridge_channel.h?view=diff&rev=419687&r1=419686&r2=419687
==============================================================================
--- team/group/ari-greedy-atxfer/include/asterisk/bridge_channel.h (original)
+++ team/group/ari-greedy-atxfer/include/asterisk/bridge_channel.h Mon Jul 28 13:54:43 2014
@@ -162,8 +162,6 @@
 		/*! Digit currently sending into the bridge. (zero if not sending) */
 		char dtmf_digit;
 	} owed;
-	/*! Callback to call if the bridge channel is being moved from one bridge to another. */
-	void (*bein_moved)(struct ast_bridge_channel *bridge_channel, struct ast_bridge *src, struct ast_bridge *dst);
 };
 
 /*!

Modified: team/group/ari-greedy-atxfer/res/stasis/stasis_bridge.c
URL: http://svnview.digium.com/svn/asterisk/team/group/ari-greedy-atxfer/res/stasis/stasis_bridge.c?view=diff&rev=419687&r1=419686&r2=419687
==============================================================================
--- team/group/ari-greedy-atxfer/res/stasis/stasis_bridge.c (original)
+++ team/group/ari-greedy-atxfer/res/stasis/stasis_bridge.c Mon Jul 28 13:54:43 2014
@@ -34,8 +34,6 @@
 #include "asterisk/bridge.h"
 #include "asterisk/bridge_after.h"
 #include "asterisk/bridge_internal.h"
-#include "asterisk/stasis_app.h"
-#include "asterisk/stasis_channels.h"
 #include "stasis_bridge.h"
 #include "control.h"
 #include "command.h"
@@ -44,8 +42,6 @@
 #include "asterisk/pbx.h"
 
 /* ------------------------------------------------------------------- */
-
-static struct ast_bridge_methods bridge_stasis_v_table;
 
 static void bridge_stasis_run_cb(struct ast_channel *chan, void *data)
 {
@@ -142,57 +138,6 @@
 	return ast_bridge_base_v_table.push(self, bridge_channel, swap);
 }
 
-static void bridge_stasis_bein_moved(struct ast_bridge_channel *bridge_channel,
-		struct ast_bridge *src, struct ast_bridge *dst)
-{
-	if (src->v_table == &bridge_stasis_v_table &&
-			dst->v_table != &bridge_stasis_v_table) {
-		/* Send the stasis end here. Need the app name for that... */
-		RAII_VAR(struct ast_json *, msg, NULL, ast_json_unref);
-		RAII_VAR(struct ast_channel_snapshot *, snapshot, NULL, ao2_cleanup);
-		RAII_VAR(struct stasis_app_control *, control, NULL, ao2_cleanup);
-		struct stasis_message_sanitizer *sanitize = stasis_app_get_sanitizer();
-		struct stasis_app *app;
-		struct ast_channel *chan;
-
-		chan = bridge_channel->chan;
-		ast_assert(chan != NULL);
-
-		control = stasis_app_control_find_by_channel(chan);
-		if (!control) {
-			return;
-		}
-		app = control_app(control);
-		if (!app) {
-			return;
-		}
-
-		/* Set channel info */
-		ast_channel_lock(chan);
-		snapshot = ast_channel_snapshot_create(chan);
-		ast_channel_unlock(chan);
-		if (snapshot == NULL) {
-			return;
-		}
-
-		if (sanitize && sanitize->channel_snapshot
-			&& sanitize->channel_snapshot(snapshot)) {
-			return;
-		}
-
-		msg = ast_json_pack("{s: s, s: o, s: o}",
-			"type", "StasisEnd",
-			"timestamp", ast_json_timeval(ast_tvnow(), NULL),
-			"channel", ast_channel_snapshot_to_json(snapshot, NULL));
-		if (!msg) {
-			return;
-		}
-
-		app_send(app, msg);
-		return;
-	}
-}
-
 /*!
  * \internal
  * \brief Pull this channel from the Stasis bridge.
@@ -212,10 +157,10 @@
 		ast_bridge_channel_update_accountcodes(NULL, bridge_channel);
 	}
 
-	bridge_channel->bein_moved = bridge_stasis_bein_moved;
-
 	ast_bridge_base_v_table.pull(self, bridge_channel);
 }
+
+static struct ast_bridge_methods bridge_stasis_v_table;
 
 struct ast_bridge *bridge_stasis_new(uint32_t capabilities, unsigned int flags, const char *name, const char *id)
 {




More information about the asterisk-commits mailing list