diff options
author | Mnikolenko Productengine <mnikolenko@productengine.com> | 2020-11-13 15:45:39 +0200 |
---|---|---|
committer | Mnikolenko Productengine <mnikolenko@productengine.com> | 2020-11-13 15:45:39 +0200 |
commit | 2d84f8f6c89e0a3f0d4f692e6280eb53500d6393 (patch) | |
tree | 33dfa0a1d12d2acf32756b704b06e0e859a364f5 | |
parent | 674f12f681c4b405400194a35496a8e1ff77b3e5 (diff) |
SL-14312 Show simulator host names for AWS hosted regions
-rw-r--r-- | indra/newview/llappviewer.cpp | 6 | ||||
-rw-r--r-- | indra/newview/llviewerregion.cpp | 9 | ||||
-rw-r--r-- | indra/newview/llviewerregion.h | 2 |
3 files changed, 13 insertions, 4 deletions
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index ff45fd0f61..808a9d63c6 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -3141,7 +3141,7 @@ LLSD LLAppViewer::getViewerInfo() const info["REGION"] = gAgent.getRegion()->getName(); boost::regex regex("\\.(secondlife|lindenlab)\\..*"); - info["HOSTNAME"] = boost::regex_replace(gAgent.getRegion()->getHost().getHostName(), regex, ""); + info["HOSTNAME"] = boost::regex_replace(gAgent.getRegion()->getSimHostName(), regex, ""); info["SERVER_VERSION"] = gLastVersionChannel; LLSLURL slurl; LLAgentUI::buildSLURL(slurl); @@ -3597,7 +3597,7 @@ void LLAppViewer::handleViewerCrash() if(gAgent.getRegion()) { - gDebugInfo["Dynamic"]["CurrentSimHost"] = gAgent.getRegionHost().getHostName(); + gDebugInfo["Dynamic"]["CurrentSimHost"] = gAgent.getRegion()->getSimHostName(); gDebugInfo["Dynamic"]["CurrentRegion"] = gAgent.getRegion()->getName(); const LLVector3& loc = gAgent.getPositionAgent(); @@ -5616,7 +5616,7 @@ void LLAppViewer::handleLoginComplete() if(gAgent.getRegion()) { - gDebugInfo["CurrentSimHost"] = gAgent.getRegionHost().getHostName(); + gDebugInfo["CurrentSimHost"] = gAgent.getRegion()->getSimHostName(); gDebugInfo["CurrentRegion"] = gAgent.getRegion()->getName(); } diff --git a/indra/newview/llviewerregion.cpp b/indra/newview/llviewerregion.cpp index 6ccf38cd27..2fde4fe49c 100644 --- a/indra/newview/llviewerregion.cpp +++ b/indra/newview/llviewerregion.cpp @@ -3361,5 +3361,12 @@ U32 LLViewerRegion::getMaxMaterialsPerTransaction() const return max_entries; } - +std::string LLViewerRegion::getSimHostName() +{ + if (mSimulatorFeaturesReceived) + { + return mSimulatorFeatures.has("HostName") ? mSimulatorFeatures["HostName"].asString() : getHost().getHostName(); + } + return std::string("..."); +} diff --git a/indra/newview/llviewerregion.h b/indra/newview/llviewerregion.h index 477aabb971..dfd8c64f76 100644 --- a/indra/newview/llviewerregion.h +++ b/indra/newview/llviewerregion.h @@ -393,6 +393,8 @@ public: BOOL isPaused() const {return mPaused;} S32 getLastUpdate() const {return mLastUpdate;} + std::string getSimHostName(); + static BOOL isNewObjectCreationThrottleDisabled() {return sNewObjectCreationThrottle < 0;} private: |