From 92bdd1d13f3964a01716be7430ec510a73050976 Mon Sep 17 00:00:00 2001 From: Andrey Kleshchev Date: Mon, 18 May 2020 15:03:06 +0300 Subject: SL-13265 "Empty leaf" crash safeguards --- indra/newview/llspatialpartition.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/newview/llspatialpartition.cpp') diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp index 77bbcdada6..d39c3d3ea8 100644 --- a/indra/newview/llspatialpartition.cpp +++ b/indra/newview/llspatialpartition.cpp @@ -3123,13 +3123,13 @@ void renderRaycast(LLDrawable* drawablep) LLGLEnable blend(GL_BLEND); gGL.diffuseColor4f(0,1,1,0.5f); - if (drawablep->getVOVolume()) + LLVOVolume* vobj = drawablep->getVOVolume(); + if (vobj && !vobj->isDead()) { //glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); //pushVerts(drawablep->getFace(gDebugRaycastFaceHit), LLVertexBuffer::MAP_VERTEX); //glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); - LLVOVolume* vobj = drawablep->getVOVolume(); LLVolume* volume = vobj->getVolume(); bool transform = true; @@ -3358,7 +3358,7 @@ public: for (OctreeNode::const_element_iter i = branch->getDataBegin(); i != branch->getDataEnd(); ++i) { LLDrawable* drawable = (LLDrawable*)(*i)->getDrawable(); - if(!drawable) + if(!drawable || drawable->isDead()) { continue; } -- cgit v1.2.3