Commits

Vadim Savchuk committed b139096

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.

Comments (0)

Files changed (2)

doc/contributions.txt

 	SNOW-390
 	SNOW-421
 	SNOW-462
+	SNOW-635
 	SNOW-586
 	SNOW-743
 	VWR-7109

indra/newview/llselectmgr.cpp

 	mSilhouetteExists(FALSE),
 	mDuplicated(FALSE),
 	mTESelectMask(0),
-	mLastTESelected(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;
-
+	mLastTESelected(0),
+	mName(LLStringUtil::null),
+	mDescription(LLStringUtil::null),
+	mTouchName(LLStringUtil::null),
+	mSitName(LLStringUtil::null),
+	mCreationDate(0)
+{
 	saveColors();
 }