aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs12
1 files changed, 11 insertions, 1 deletions
diff --git a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
index df0be97..0d9fd94 100644
--- a/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
+++ b/OpenSim/Region/CoreModules/Avatar/Friends/FriendsModule.cs
@@ -191,7 +191,17 @@ namespace OpenSim.Region.CoreModules.Avatar.Friends
191 191
192 public uint GetFriendPerms(UUID principalID, UUID friendID) 192 public uint GetFriendPerms(UUID principalID, UUID friendID)
193 { 193 {
194 return 1; 194 if (!m_Friends.ContainsKey(principalID))
195 return 0;
196
197 UserFriendData data = m_Friends[principalID];
198
199 foreach (FriendInfo fi in data.Friends)
200 {
201 if (fi.Friend == friendID.ToString())
202 return (uint)fi.TheirFlags;
203 }
204 return 0;
195 } 205 }
196 206
197 private byte[] FailureResult() 207 private byte[] FailureResult()