summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xindra/newview/llvoicevivox.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/indra/newview/llvoicevivox.cpp b/indra/newview/llvoicevivox.cpp
index e4b045bdeb..77ce2d9b8f 100755
--- a/indra/newview/llvoicevivox.cpp
+++ b/indra/newview/llvoicevivox.cpp
@@ -1538,8 +1538,9 @@ void LLVivoxVoiceClient::stateMachine()
// Must do this first, since it uses mAudioSession.
notifyStatusObservers(LLVoiceClientStatusObserver::STATUS_LEFT_CHANNEL);
- if (mAudioSession)
+ if (mAudioSession && mSessionTerminateRequested)
{
+ // will only go this section on the frist frame when a call is being cancelled.
leaveAudioSession();
sessionState *oldSession = mAudioSession;
@@ -1556,6 +1557,8 @@ void LLVivoxVoiceClient::stateMachine()
}
// Always reset the terminate request flag when we get here.
+ // Some slower PCs have a race condition where they can switch to an incoming P2P call faster than the state machine leaves
+ // the region chat.
mSessionTerminateRequested = false;
if((mVoiceEnabled || !mIsInitialized) && !mRelogRequested && !LLApp::isExiting())
@@ -3176,6 +3179,9 @@ void LLVivoxVoiceClient::leftAudioSession(
break;
}
}
+ else if ( mAudioSession == NULL && (getState() == stateSessionTerminated) ){
+ setState(stateNoChannel);
+ }
}
void LLVivoxVoiceClient::accountLoginStateChangeEvent(