From 483e22a64d4d8c56a0ac0a3d7df50c4860985446 Mon Sep 17 00:00:00 2001 From: Vadim Savchuk Date: Tue, 21 Sep 2010 17:41:53 +0300 Subject: STORM-166 FIXED Memory leak in LLSelectNode constructor. Submitting on behalf of Thickbrick Sleaford. One of the LLSelectNode constructors has a leak where it does "new LLPermisions()" twice, thus leaking the address of the first object created. This constructor is called every time you interact (click, hover, select, possibly other) with an object, once for each prim in the object. Since sizeof(LLPermissions) is 92 bytes, this can be a significant amount after a while. I think this might explain VWR-18528 (leaking LLpemissions instances), at least partially. This was fixed in snowglobe 1.x as part of SNOW-267. --- doc/contributions.txt | 1 + indra/newview/llselectmgr.cpp | 22 ++++++---------------- 2 files changed, 7 insertions(+), 16 deletions(-) diff --git a/doc/contributions.txt b/doc/contributions.txt index d58539dd71..e48924d0f6 100644 --- a/doc/contributions.txt +++ b/doc/contributions.txt @@ -661,6 +661,7 @@ Thickbrick Sleaford SNOW-390 SNOW-421 SNOW-462 + SNOW-635 SNOW-586 SNOW-743 VWR-7109 diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp index fb60b1ece7..9260abb2ac 100644 --- a/indra/newview/llselectmgr.cpp +++ b/indra/newview/llselectmgr.cpp @@ -5058,23 +5058,13 @@ LLSelectNode::LLSelectNode(LLViewerObject* object, BOOL glow) mSilhouetteExists(FALSE), mDuplicated(FALSE), mTESelectMask(0), - mLastTESelected(0) + mLastTESelected(0), + mName(LLStringUtil::null), + mDescription(LLStringUtil::null), + mTouchName(LLStringUtil::null), + mSitName(LLStringUtil::null), + mCreationDate(0) { - mObject = object; - selectAllTEs(FALSE); - mIndividualSelection = FALSE; - mTransient = FALSE; - mValid = FALSE; - mPermissions = new LLPermissions(); - mInventorySerial = 0; - mName = LLStringUtil::null; - mDescription = LLStringUtil::null; - mTouchName = LLStringUtil::null; - mSitName = LLStringUtil::null; - mSilhouetteExists = FALSE; - mDuplicated = FALSE; - mCreationDate = 0; - saveColors(); } -- cgit v1.2.3