diff options
| author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2024-07-22 18:54:09 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-22 18:54:09 +0300 |
| commit | dc2aab4ee42e4e7ecf14d475b803446fee422cbb (patch) | |
| tree | e69eb8ce7fb2857ba24c348b7b738fd962591e4b /indra/newview/llimview.cpp | |
| parent | 75fb5c0d5e54c36327cfdca17e6ccc1682743fe0 (diff) | |
| parent | 15877bf396f1b37784a8449540335960190862d0 (diff) | |
Merge pull request #2085 from RyeMutt/crash-fixes
Fix various nullptr crashes
Diffstat (limited to 'indra/newview/llimview.cpp')
| -rw-r--r-- | indra/newview/llimview.cpp | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp index b12c2fdc52..33e6d2d1b2 100644 --- a/indra/newview/llimview.cpp +++ b/indra/newview/llimview.cpp @@ -3042,13 +3042,16 @@ void LLIncomingCallDialog::processCallResponse(S32 response, const LLSD &payload gIMMgr->addSession(correct_session_name, type, session_id, payload["voice_channel_info"]); - std::string url = gAgent.getRegion()->getCapability( + std::string url = gAgent.getRegionCapability( "ChatSessionRequest"); if (voice) { - LLCoros::instance().launch("chatterBoxInvitationCoro", - boost::bind(&chatterBoxInvitationCoro, url, session_id, inv_type, payload["voice_channel_info"])); + if(!url.empty()) + { + LLCoros::instance().launch("chatterBoxInvitationCoro", + boost::bind(&chatterBoxInvitationCoro, url, session_id, inv_type, payload["voice_channel_info"])); + } // send notification message to the corresponding chat if (payload["notify_box_type"].asString() == "VoiceInviteGroup" || payload["notify_box_type"].asString() == "VoiceInviteAdHoc") @@ -4063,9 +4066,12 @@ public: // Send request for chat history, if enabled. if (gSavedPerAccountSettings.getBOOL("FetchGroupChatHistory")) { - std::string url = gAgent.getRegion()->getCapability("ChatSessionRequest"); - LLCoros::instance().launch("chatterBoxHistoryCoro", - boost::bind(&chatterBoxHistoryCoro, url, session_id, "", "", 0)); + std::string url = gAgent.getRegionCapability("ChatSessionRequest"); + if (!url.empty()) + { + LLCoros::instance().launch("chatterBoxHistoryCoro", + boost::bind(&chatterBoxHistoryCoro, url, session_id, "", "", 0)); + } } } } |
