Skip to content
Snippets Groups Projects
Commit 5238a39b authored by Merov Linden's avatar Merov Linden
Browse files

CHUI-552 : Fixed : Filter out participant creation with the same id than the session id

parent 1a9a5508
No related branches found
No related tags found
No related merge requests found
...@@ -366,8 +366,11 @@ bool LLParticipantList::onSpeakerMuteEvent(LLPointer<LLOldEvents::LLEvent> event ...@@ -366,8 +366,11 @@ bool LLParticipantList::onSpeakerMuteEvent(LLPointer<LLOldEvents::LLEvent> event
void LLParticipantList::addAvatarIDExceptAgent(const LLUUID& avatar_id) void LLParticipantList::addAvatarIDExceptAgent(const LLUUID& avatar_id)
{ {
// Do not add if already in there or excluded for some reason // Do not add if already in there, is the session id (hence not an avatar) or excluded for some reason
if (findParticipant(avatar_id)) return; if (findParticipant(avatar_id) || (avatar_id == mUUID))
{
return;
}
bool is_avatar = LLVoiceClient::getInstance()->isParticipantAvatar(avatar_id); bool is_avatar = LLVoiceClient::getInstance()->isParticipantAvatar(avatar_id);
...@@ -391,7 +394,7 @@ void LLParticipantList::addAvatarIDExceptAgent(const LLUUID& avatar_id) ...@@ -391,7 +394,7 @@ void LLParticipantList::addAvatarIDExceptAgent(const LLUUID& avatar_id)
// *TODO : Need to update the online/offline status of the participant // *TODO : Need to update the online/offline status of the participant
// Hack for this: LLAvatarTracker::instance().isBuddyOnline(avatar_id)) // Hack for this: LLAvatarTracker::instance().isBuddyOnline(avatar_id))
// Add the participant model to the session's children list // Add the participant model to the session's children list
addParticipant(participant); addParticipant(participant);
...@@ -413,12 +416,12 @@ void LLParticipantList::adjustParticipant(const LLUUID& speaker_id) ...@@ -413,12 +416,12 @@ void LLParticipantList::adjustParticipant(const LLUUID& speaker_id)
bool LLParticipantList::SpeakerAddListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata) bool LLParticipantList::SpeakerAddListener::handleEvent(LLPointer<LLOldEvents::LLEvent> event, const LLSD& userdata)
{ {
/** /**
* We need to filter speaking objects. These objects shouldn't appear in the list * We need to filter speaking objects. These objects shouldn't appear in the list.
* @see LLFloaterChat::addChat() in llviewermessage.cpp to get detailed call hierarchy * @see LLFloaterChat::addChat() in llviewermessage.cpp to get detailed call hierarchy
*/ */
const LLUUID& speaker_id = event->getValue().asUUID(); const LLUUID& speaker_id = event->getValue().asUUID();
LLPointer<LLSpeaker> speaker = mParent.mSpeakerMgr->findSpeaker(speaker_id); LLPointer<LLSpeaker> speaker = mParent.mSpeakerMgr->findSpeaker(speaker_id);
if(speaker.isNull() || speaker->mType == LLSpeaker::SPEAKER_OBJECT) if (speaker.isNull() || (speaker->mType == LLSpeaker::SPEAKER_OBJECT))
{ {
return false; return false;
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment