aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Data/MSSQL/MSSQLPresenceData.cs
diff options
context:
space:
mode:
authorBlueWall2012-12-09 15:08:32 -0500
committerBlueWall2012-12-09 15:08:32 -0500
commit8efae93b51082e0af9048306ffa8ca82586969af (patch)
treed320388f5a202374a2c8a9eb43b32b290e4ad920 /OpenSim/Data/MSSQL/MSSQLPresenceData.cs
parentMerge branch 'master' of /home/opensim/var/repo/opensim (diff)
downloadopensim-SC_OLD-8efae93b51082e0af9048306ffa8ca82586969af.zip
opensim-SC_OLD-8efae93b51082e0af9048306ffa8ca82586969af.tar.gz
opensim-SC_OLD-8efae93b51082e0af9048306ffa8ca82586969af.tar.bz2
opensim-SC_OLD-8efae93b51082e0af9048306ffa8ca82586969af.tar.xz
Restrict IPresenceData.VerifyAgent
Restrict IPresenceData.VerifyAgent to only return bool result
Diffstat (limited to '')
-rw-r--r--OpenSim/Data/MSSQL/MSSQLPresenceData.cs12
1 files changed, 7 insertions, 5 deletions
diff --git a/OpenSim/Data/MSSQL/MSSQLPresenceData.cs b/OpenSim/Data/MSSQL/MSSQLPresenceData.cs
index 5f495ae..0c71e79 100644
--- a/OpenSim/Data/MSSQL/MSSQLPresenceData.cs
+++ b/OpenSim/Data/MSSQL/MSSQLPresenceData.cs
@@ -100,16 +100,18 @@ namespace OpenSim.Data.MSSQL
100 return true; 100 return true;
101 } 101 }
102 102
103 public PresenceData VerifyAgent(UUID secureSessionID) 103 public bool VerifyAgent(UUID agentId, UUID secureSessionID)
104 { 104 {
105 PresenceData[] ret = Get("SecureSessionID", 105 PresenceData[] ret = Get("SecureSessionID",
106 secureSessionID.ToString()); 106 secureSessionID.ToString());
107 107
108 if (ret.Length == 0) 108 if (ret.Length == 0)
109 return null; 109 return false;
110 110
111 return ret[0]; 111 if(ret[0].UserID != agentId.ToString())
112 } 112 return false;
113 113
114 return true;
115 }
114 } 116 }
115} 117}