From 1521221e56de368a3b28c170a1e69e3c7dde7507 Mon Sep 17 00:00:00 2001 From: Cosmic Linden Date: Tue, 26 Jul 2022 11:31:01 -0700 Subject: [PATCH 1/4] SL-17826: Fix index out of bounds in mOwnership when drawing parcel lines --- indra/newview/llviewerparceloverlay.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/indra/newview/llviewerparceloverlay.cpp b/indra/newview/llviewerparceloverlay.cpp index 31587549e8..785c84c38d 100755 --- a/indra/newview/llviewerparceloverlay.cpp +++ b/indra/newview/llviewerparceloverlay.cpp @@ -1068,13 +1068,14 @@ void LLViewerParcelOverlay::renderPropertyLinesOnMinimap(F32 scale_pixels_per_me gGL.color4fv(parcel_outline_color); for (S32 i = 0; i < GRIDS_PER_EDGE + 1; i++) { - F32 bottom = region_bottom + (i * map_parcel_width); - F32 top = bottom + map_parcel_width; + const F32 bottom = region_bottom + (i * map_parcel_width); + const F32 top = bottom + map_parcel_width; for (S32 j = 0; j < GRIDS_PER_EDGE + 1; j++) { - F32 left = region_left + (j * map_parcel_width); - F32 right = left + map_parcel_width; - U8 overlay = mOwnership[(i * GRIDS_PER_EDGE) + j]; + const F32 left = region_left + (j * map_parcel_width); + const F32 right = left + map_parcel_width; + const bool is_region_boundary = i == GRIDS_PER_EDGE || j == GRIDS_PER_EDGE; + const U8 overlay = is_region_boundary ? 0 : mOwnership[(i * GRIDS_PER_EDGE) + j]; // The property line vertices are three-dimensional, but here we only care about the x and y coordinates, as we are drawing on a // 2D map const bool has_left = i != GRIDS_PER_EDGE && (j == GRIDS_PER_EDGE || (overlay & PARCEL_WEST_LINE)); From faeded36578612a9bea970fd5b2f02e5d73e0af1 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Tue, 26 Jul 2022 21:21:08 +0300 Subject: [PATCH 2/4] SL-17827 Crash at LLCamera::setViewHeightInPixels --- indra/newview/llviewerwindow.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp index bc69fd80db..2deb2928b9 100644 --- a/indra/newview/llviewerwindow.cpp +++ b/indra/newview/llviewerwindow.cpp @@ -2511,10 +2511,11 @@ void LLViewerWindow::reshape(S32 width, S32 height) //glViewport(0, 0, width, height ); - if (height > 0) + LLViewerCamera * camera = LLViewerCamera::getInstance(); // simpleton, might not exist + if (height > 0 && camera) { - LLViewerCamera::getInstance()->setViewHeightInPixels( mWorldViewRectRaw.getHeight() ); - LLViewerCamera::getInstance()->setAspect( getWorldViewAspectRatio() ); + camera->setViewHeightInPixels( mWorldViewRectRaw.getHeight() ); + camera->setAspect( getWorldViewAspectRatio() ); } calcDisplayScale(); From 2a48c195301490e289ce7cf423b34e08028aae02 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Tue, 26 Jul 2022 21:43:44 +0300 Subject: [PATCH 3/4] SL-17828 Crash at LLPolyMorphData::loadBinary These files are usually prepackaged with viewer, either all issues should lead to an error or all issues should use warns. I don't think it is a critical issue, so instead of crashing, printing out filename. --- indra/llappearance/llpolymesh.cpp | 8 +++++--- indra/llappearance/llpolymorph.cpp | 4 +++- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/indra/llappearance/llpolymesh.cpp b/indra/llappearance/llpolymesh.cpp index 0a7a8d27bb..3892e4ce43 100644 --- a/indra/llappearance/llpolymesh.cpp +++ b/indra/llappearance/llpolymesh.cpp @@ -612,14 +612,16 @@ BOOL LLPolyMeshSharedData::loadMesh( const std::string& fileName ) // we reached the end of the morphs break; } - LLPolyMorphData* morph_data = new LLPolyMorphData(std::string(morphName)); + std::string morph_name(morphName); + LLPolyMorphData* morph_data = new LLPolyMorphData(morph_name); BOOL result = morph_data->loadBinary(fp, this); if (!result) { - delete morph_data; - continue; + LL_WARNS() << "Failure loading " << morph_name << " from " << fileName << LL_ENDL; + delete morph_data; + continue; } mMorphData.insert(morph_data); diff --git a/indra/llappearance/llpolymorph.cpp b/indra/llappearance/llpolymorph.cpp index 16b5f1e204..84dd6156a9 100644 --- a/indra/llappearance/llpolymorph.cpp +++ b/indra/llappearance/llpolymorph.cpp @@ -156,7 +156,9 @@ BOOL LLPolyMorphData::loadBinary(LLFILE *fp, LLPolyMeshSharedData *mesh) if (mVertexIndices[v] > 10000) { - LL_ERRS() << "Bad morph index: " << mVertexIndices[v] << LL_ENDL; + // Bad install? These are usually .llm files from 'character' fodler + LL_WARNS() << "Bad morph index " << v << ": " << mVertexIndices[v] << LL_ENDL; + return FALSE; } From 9664eb86339f1cffac51cd0a5339535a040cada5 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Wed, 27 Jul 2022 21:17:56 +0300 Subject: [PATCH 4/4] SL-17831 Cut spammy log message --- indra/newview/llvoicevivox.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/indra/newview/llvoicevivox.cpp b/indra/newview/llvoicevivox.cpp index 54f79a3a2e..5f1624d4fd 100644 --- a/indra/newview/llvoicevivox.cpp +++ b/indra/newview/llvoicevivox.cpp @@ -1625,7 +1625,14 @@ bool LLVivoxVoiceClient::requestParcelVoiceInfo() } else { - LL_WARNS("Voice") << "No voice credentials" << LL_ENDL; + if (LLViewerParcelMgr::getInstance()->allowAgentVoice()) + { + LL_WARNS("Voice") << "No voice credentials" << LL_ENDL; + } + else + { + LL_DEBUGS("Voice") << "No voice credentials" << LL_ENDL; + } } // set the spatial channel. If no voice credentials or uri are