diff --git a/indra/newview/llavatarlist.cpp b/indra/newview/llavatarlist.cpp
index 676e8a5d80a1d0a5b11cf51771a9515484ce2444..3ac276f95c7a7ede680bd574b309abdb9d2976a8 100644
--- a/indra/newview/llavatarlist.cpp
+++ b/indra/newview/llavatarlist.cpp
@@ -178,7 +178,7 @@ void LLAvatarList::setShowIcons(std::string param_name)
 	mShowIcons = gSavedSettings.getBOOL(mIconParamName);
 }
 
-std::string LLAvatarList::getAvatarName(LLAvatarName av_name)
+std::string LLAvatarList::getAvatarName(const LLAvatarName& av_name)
 {
 	return mShowCompleteName? av_name.getCompleteName(false) : av_name.getDisplayName();
 }
diff --git a/indra/newview/llavatarlist.h b/indra/newview/llavatarlist.h
index 0613434ebb4ae76db4509c4dc1a65bfca7d86088..51bce0c24639d1c9497028459ca9471cfa0a3709 100644
--- a/indra/newview/llavatarlist.h
+++ b/indra/newview/llavatarlist.h
@@ -83,7 +83,7 @@ class LLAvatarList : public LLFlatListViewEx
 	void setShowIcons(std::string param_name);
 	bool getIconsVisible() const { return mShowIcons; }
 	const std::string getIconParamName() const{return mIconParamName;}
-	std::string getAvatarName(LLAvatarName av_name);
+	std::string getAvatarName(const LLAvatarName& av_name);
 	virtual BOOL handleRightMouseDown(S32 x, S32 y, MASK mask);
 	/*virtual*/ BOOL handleMouseDown( S32 x, S32 y, MASK mask );
 	/*virtual*/ BOOL handleMouseUp(S32 x, S32 y, MASK mask);