diff options
| -rw-r--r-- | indra/newview/llvoicevivox.cpp | 13 | 
1 files changed, 11 insertions, 2 deletions
| diff --git a/indra/newview/llvoicevivox.cpp b/indra/newview/llvoicevivox.cpp index 2584f4b9a4..ae4b065333 100644 --- a/indra/newview/llvoicevivox.cpp +++ b/indra/newview/llvoicevivox.cpp @@ -658,6 +658,8 @@ void LLVivoxVoiceClient::voiceControlCoro()      mIsCoroutineActive = true;      LLCoros::set_consuming(true); +    U32 retry = 0; +      while (gAgent.getTeleportState() != LLAgent::TELEPORT_NONE)      {          LL_DEBUGS("Voice") << "Suspending voiceControlCoro() momentarily for teleport. Tuning: " << mTuningMode << ". Relog: " << mRelogRequested << LL_ENDL; @@ -678,6 +680,7 @@ void LLVivoxVoiceClient::voiceControlCoro()              LL_DEBUGS("Voice") << "lost channel RelogRequested=" << mRelogRequested << LL_ENDL;                          endAndDisconnectSession(); +            retry = 0;          }          // if we hit this and mRelogRequested is true, that indicates @@ -693,10 +696,16 @@ void LLVivoxVoiceClient::voiceControlCoro()              if (!success)              {                  // We failed to connect, give it a bit time before retrying. -                llcoro::suspendUntilTimeout(5.0); +                retry++; +                F32 delay = llmin(5.f * (F32)retry, 60.f); +                llcoro::suspendUntilTimeout(delay); +                LL_INFOS("Voice") << "Voice failed to establish session after " << retry << " tries. Will attempt to reconnect." << LL_ENDL; +            } +            else +            { +                LL_INFOS("Voice") << "will attempt to reconnect to voice" << LL_ENDL;              } -            LL_INFOS("Voice") << "will attempt to reconnect to voice" << LL_ENDL;              while (isGatewayRunning() || gAgent.getTeleportState() != LLAgent::TELEPORT_NONE)              {                  LL_INFOS("Voice") << "waiting for SLVoice to exit" << LL_ENDL; | 
