From c2de0c930c526157b464ce7a7d17a37042a3676c Mon Sep 17 00:00:00 2001 From: Melanie Date: Sat, 23 Jul 2011 18:29:43 +0200 Subject: [PATCH] Fix failure to find avatars due to trainling spaces being sent by viewers. --- OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs | 3 +++ OpenSim/Services/UserAccountService/UserAccountService.cs | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs index 44472b2cb7..9bef44322a 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs @@ -378,7 +378,10 @@ namespace OpenSim.Region.Framework.Scenes List accounts = UserAccountService.GetUserAccounts(RegionInfo.ScopeID, query); if (accounts == null) + { + m_log.DebugFormat("[LLCIENT]: ProcessAvatarPickerRequest: returned null result"); return; + } AvatarPickerReplyPacket replyPacket = (AvatarPickerReplyPacket) PacketPool.Instance.GetPacket(PacketType.AvatarPickerReply); // TODO: don't create new blocks if recycling an old packet diff --git a/OpenSim/Services/UserAccountService/UserAccountService.cs b/OpenSim/Services/UserAccountService/UserAccountService.cs index dbf5ef4ded..7a46165aa2 100644 --- a/OpenSim/Services/UserAccountService/UserAccountService.cs +++ b/OpenSim/Services/UserAccountService/UserAccountService.cs @@ -288,7 +288,7 @@ namespace OpenSim.Services.UserAccountService public List GetUserAccounts(UUID scopeID, string query) { - UserAccountData[] d = m_Database.GetUsers(scopeID, query); + UserAccountData[] d = m_Database.GetUsers(scopeID, query.Trim()); if (d == null) return new List();