diff options
author | Howard Stearns <howard.stearns@gmail.com> | 2021-12-22 15:10:50 -0800 |
---|---|---|
committer | Howard Stearns <howard.stearns@gmail.com> | 2021-12-22 15:10:50 -0800 |
commit | 96e0c823412cc0419a730714992b4fc25316deb0 (patch) | |
tree | b088d30fcf9c43a9919f877eab1a786174469309 | |
parent | 1c2e66e12d8659424a01670f641fe4f814b9b4b9 (diff) |
Show both server/voice versions only if mismatched. Otherwise show the longer one.
-rw-r--r-- | indra/newview/llappviewer.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp index 4cc5ae7630..58a164f1d0 100644 --- a/indra/newview/llappviewer.cpp +++ b/indra/newview/llappviewer.cpp @@ -3209,9 +3209,18 @@ LLSD LLAppViewer::getViewerInfo() const if(LLVoiceClient::getInstance()->voiceEnabled()) { auto& licenseInfo(LLLicenseInfo::instance()); + std::string detailed_version = licenseInfo.getVersion("slvoice"); LLVoiceVersionInfo version = LLVoiceClient::getInstance()->getVersion(); std::ostringstream version_string; - version_string << version.serverType << " " << version.serverVersion << " SLVoice " << licenseInfo.getVersion("slvoice") << std::endl; + if (std::equal(detailed_version.begin(), detailed_version.begin() + version.serverVersion.size(), + version.serverVersion.begin())) + { // Normal case: Show type and detailed version. + version_string << version.serverType << " " << detailed_version << std::endl; + } + else + { // Mismatch: Show both versions. + version_string << version.serverVersion << "/" << detailed_version << std::endl; + } info["VOICE_VERSION"] = version_string.str(); } else |