diff options
| -rw-r--r-- | indra/newview/llmutelist.cpp | 15 | ||||
| -rw-r--r-- | indra/newview/llstartup.cpp | 20 | ||||
| -rw-r--r-- | indra/newview/llstatusbar.cpp | 15 | 
3 files changed, 40 insertions, 10 deletions
diff --git a/indra/newview/llmutelist.cpp b/indra/newview/llmutelist.cpp index 663a6071f7..4a8ef53a8b 100644 --- a/indra/newview/llmutelist.cpp +++ b/indra/newview/llmutelist.cpp @@ -726,7 +726,20 @@ void LLMuteList::requestFromServer(const LLUUID& agent_id)  	msg->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID());  	msg->nextBlockFast(_PREHASH_MuteData);  	msg->addU32Fast(_PREHASH_MuteCRC, crc.getCRC()); -	gAgent.sendReliableMessage(); + +    if (gDisconnected) +    { +        LL_WARNS() << "Trying to request mute list when disconnected!" << LL_ENDL; +        return; +    } +    if (!gAgent.getRegion()) +    { +        LL_WARNS() << "No region for agent yet, skipping mute list request!" << LL_ENDL; +        return; +    } +    // Double amount of retries due to this request happening during busy stage +    // Ideally this should be turned into a capability +    gMessageSystem->sendReliable(gAgent.getRegionHost(), LL_DEFAULT_RELIABLE_RETRIES * 2, TRUE, LL_PING_BASED_TIMEOUT_DUMMY, NULL, NULL);  }  //----------------------------------------------------------------------------- diff --git a/indra/newview/llstartup.cpp b/indra/newview/llstartup.cpp index 85b578730e..ba39cf083d 100644 --- a/indra/newview/llstartup.cpp +++ b/indra/newview/llstartup.cpp @@ -1668,8 +1668,20 @@ bool idle_startup()  	if (STATE_INVENTORY_SEND == LLStartUp::getStartupState())  	{  		display_startup(); + +        // request mute list +        LL_INFOS() << "Requesting Mute List" << LL_ENDL; +        LLMuteList::getInstance()->requestFromServer(gAgent.getID()); + +        // Get L$ and ownership credit information +        LL_INFOS() << "Requesting Money Balance" << LL_ENDL; +        LLStatusBar::sendMoneyBalanceRequest(); + +        display_startup(); +  		// Inform simulator of our language preference  		LLAgentLanguage::update(); +  		display_startup();  		// unpack thin inventory  		LLSD response = LLLoginInstance::getInstance()->getResponse(); @@ -1836,14 +1848,6 @@ bool idle_startup()  		LLLandmark::registerCallbacks(msg);  		display_startup(); -		// request mute list -		LL_INFOS() << "Requesting Mute List" << LL_ENDL; -		LLMuteList::getInstance()->requestFromServer(gAgent.getID()); -		display_startup(); -		// Get L$ and ownership credit information -		LL_INFOS() << "Requesting Money Balance" << LL_ENDL; -		LLStatusBar::sendMoneyBalanceRequest(); -		display_startup();  		// request all group information  		LL_INFOS() << "Requesting Agent Data" << LL_ENDL;  		gAgent.sendAgentDataUpdateRequest(); diff --git a/indra/newview/llstatusbar.cpp b/indra/newview/llstatusbar.cpp index 4d55448d78..0a87b14e17 100644 --- a/indra/newview/llstatusbar.cpp +++ b/indra/newview/llstatusbar.cpp @@ -416,7 +416,20 @@ void LLStatusBar::sendMoneyBalanceRequest()  	msg->addUUIDFast(_PREHASH_SessionID, gAgent.getSessionID());  	msg->nextBlockFast(_PREHASH_MoneyData);  	msg->addUUIDFast(_PREHASH_TransactionID, LLUUID::null ); -	gAgent.sendReliableMessage(); + +    if (gDisconnected) +    { +        LL_DEBUGS() << "Trying to send message when disconnected, skipping balance request!" << LL_ENDL; +        return; +    } +    if (!gAgent.getRegion()) +    { +        LL_DEBUGS() << "LLAgent::sendReliableMessage No region for agent yet, skipping balance request!" << LL_ENDL; +        return; +    } +    // Double amount of retries due to this request initially happening during busy stage +    // Ideally this should be turned into a capability +    gMessageSystem->sendReliable(gAgent.getRegionHost(), LL_DEFAULT_RELIABLE_RETRIES * 2, TRUE, LL_PING_BASED_TIMEOUT_DUMMY, NULL, NULL);  }  | 
