Commits

davep committed bbff5d3

EXT-8236 Massage code around crash in ~LLSpatialGroup -- looks like heap corruption.

Comments (0)

Files changed (4)

indra/newview/llspatialpartition.cpp

 	}
 
 	delete [] mOcclusionVerts;
+	mOcclusionVerts = NULL;
 
 	LLMemType mt(LLMemType::MTYPE_SPACE_PARTITION);
 	clearDrawMap();

indra/newview/llspatialpartition.h

 	static BOOL sNoDelete; //deletion of spatial groups and draw info not allowed if TRUE
 
 	typedef std::vector<LLPointer<LLSpatialGroup> > sg_vector_t;
-	typedef std::set<LLPointer<LLSpatialGroup> > sg_set_t;
-	typedef std::list<LLPointer<LLSpatialGroup> > sg_list_t;
 	typedef std::vector<LLPointer<LLSpatialBridge> > bridge_list_t;
 	typedef std::vector<LLPointer<LLDrawInfo> > drawmap_elem_t; 
 	typedef std::map<U32, drawmap_elem_t > draw_map_t;	

indra/newview/pipeline.cpp

 	assertInitialized();
 
 	// Iterate through all drawables on the priority build queue,
-	for (LLSpatialGroup::sg_list_t::iterator iter = mGroupQ1.begin();
+	for (LLSpatialGroup::sg_vector_t::iterator iter = mGroupQ1.begin();
 		 iter != mGroupQ1.end(); ++iter)
 	{
 		LLSpatialGroup* group = *iter;

indra/newview/pipeline.h

 	//
 	LLDrawable::drawable_list_t 	mBuildQ1; // priority
 	LLDrawable::drawable_list_t 	mBuildQ2; // non-priority
-	LLSpatialGroup::sg_list_t		mGroupQ1; //priority
+	LLSpatialGroup::sg_vector_t		mGroupQ1; //priority
 	LLSpatialGroup::sg_vector_t		mGroupQ2; // non-priority
 
 	LLViewerObject::vobj_list_t		mCreateQ;