[asterisk-scf-commits] asterisk-scf/integration/bridging.git branch "replacement" created.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Mon Aug 29 12:38:26 CDT 2011


branch "replacement" has been created
        at  44588bb71cc75ad4b1e9f3292f34cf60b22c743f (commit)

- Log -----------------------------------------------------------------
commit 44588bb71cc75ad4b1e9f3292f34cf60b22c743f
Author: Mark Michelson <mmichelson at digium.com>
Date:   Mon Aug 29 12:33:51 2011 -0500

    Remove code that caused transfers to be a bit goofy-like.

diff --git a/src/BridgeImpl.cpp b/src/BridgeImpl.cpp
index a9cd9e1..03d4b97 100755
--- a/src/BridgeImpl.cpp
+++ b/src/BridgeImpl.cpp
@@ -803,20 +803,7 @@ void BridgeImpl::replaceSession_async(const AMD_Bridge_replaceSessionPtr& callba
         {
             throw SessionNotFound(sessionToReplace);
         }
-        //
-        // Shutdown is inheritently asynchronous (see SessionWrapper::shutdown())
-        //
-        SessionsTrackerPtr removeTracker(new SessionsTracker);
-        removeTracker->add(session->getSession());
-        session->shutdown(mSessionListenerPrx, new ResponseCode);
 
-        //
-        // Since the shutdown of the session is inherently asynchronous, the
-        // rest of this is going to happen anyways, so lets remove it from the
-        // list of known sessions now so it doesn't get in the way.
-        //
-        mSessions->removeSession(session->getBridgedSession());
-        
         SessionsTrackerPtr tracker(new SessionsTracker);
         QueuedTasks tasks;
         BridgeCookies cookies;
@@ -824,7 +811,6 @@ void BridgeImpl::replaceSession_async(const AMD_Bridge_replaceSessionPtr& callba
             boost::shared_lock<boost::shared_mutex> lock(mLock);
             cookies = getCookies();
         }
-        tasks.push_back(new RemoveSessionsNotify(mListeners, removeTracker, cookies));
         tasks.push_back(new SetBridgeTask(mSessions, mPrx, mSessionListenerPrx, newSessions, tracker));
         tasks.push_back(new AddToListeners(mListeners, tracker, cookies));
         tasks.push_back(new GenericAMDCallback<AMD_Bridge_replaceSessionPtr>(callback, tracker));
diff --git a/src/SessionListener.cpp b/src/SessionListener.cpp
index 34d825f..fa860d9 100644
--- a/src/SessionListener.cpp
+++ b/src/SessionListener.cpp
@@ -187,18 +187,6 @@ public:
             mSessions->removeSession(session->getBridgedSession());
 
             //
-            // It's a good idea to reap at this time to avoid having processes
-            // that might be disconnected from being considered in the
-            // visitSessions() run.  TODO: Some operations shouldn't be
-            // performed on sessions in certain states. It's really the
-            // operation's responsibility to prevent that from happening.
-            //
-            mSessions->reap();
-
-            ShutdownSessionOperation shutdownOp(session->getSession(), mListenerPrx, stopped->response, mLogger);
-            mSessions->visitSessions(shutdownOp);
-
-            //
             // Ideally, we'd wait for an affirmative response from the session being removed from the bridge
             // before doing this next part. 
             //

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/bridging.git



More information about the asterisk-scf-commits mailing list