diff options
Diffstat (limited to 'OpenSim')
7 files changed, 48 insertions, 32 deletions
diff --git a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs index c5346d4..7ebb5de 100644 --- a/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs +++ b/OpenSim/ApplicationPlugins/RemoteController/RemoteAdminPlugin.cs | |||
@@ -63,7 +63,7 @@ namespace OpenSim.ApplicationPlugins.RemoteController | |||
63 | private static Object SOLock = new Object(); | 63 | private static Object SOLock = new Object(); |
64 | 64 | ||
65 | private OpenSimBase m_app; | 65 | private OpenSimBase m_app; |
66 | private BaseHttpServer m_httpd; | 66 | private IHttpServer m_httpd; |
67 | private IConfig m_config; | 67 | private IConfig m_config; |
68 | private IConfigSource m_configSource; | 68 | private IConfigSource m_configSource; |
69 | private string m_requiredPassword = String.Empty; | 69 | private string m_requiredPassword = String.Empty; |
@@ -113,9 +113,10 @@ namespace OpenSim.ApplicationPlugins.RemoteController | |||
113 | m_config = m_configSource.Configs["RemoteAdmin"]; | 113 | m_config = m_configSource.Configs["RemoteAdmin"]; |
114 | m_log.Info("[RADMIN]: Remote Admin Plugin Enabled"); | 114 | m_log.Info("[RADMIN]: Remote Admin Plugin Enabled"); |
115 | m_requiredPassword = m_config.GetString("access_password", String.Empty); | 115 | m_requiredPassword = m_config.GetString("access_password", String.Empty); |
116 | int port = m_config.GetInt("port", 0); | ||
116 | 117 | ||
117 | m_app = openSim; | 118 | m_app = openSim; |
118 | m_httpd = openSim.HttpServer; | 119 | m_httpd = MainServer.GetHttpServer((uint)port); |
119 | 120 | ||
120 | Dictionary<string, XmlRpcMethod> availableMethods = new Dictionary<string, XmlRpcMethod>(); | 121 | Dictionary<string, XmlRpcMethod> availableMethods = new Dictionary<string, XmlRpcMethod>(); |
121 | availableMethods["admin_create_region"] = XmlRpcCreateRegionMethod; | 122 | availableMethods["admin_create_region"] = XmlRpcCreateRegionMethod; |
diff --git a/OpenSim/Framework/AgentCircuitManager.cs b/OpenSim/Framework/AgentCircuitManager.cs index 49d7822..1ce8c34 100644 --- a/OpenSim/Framework/AgentCircuitManager.cs +++ b/OpenSim/Framework/AgentCircuitManager.cs | |||
@@ -92,7 +92,7 @@ namespace OpenSim.Framework | |||
92 | else | 92 | else |
93 | { | 93 | { |
94 | AgentCircuits.Add(circuitCode, agentData); | 94 | AgentCircuits.Add(circuitCode, agentData); |
95 | AgentCircuitsByUUID.Add(agentData.AgentID, agentData); | 95 | AgentCircuitsByUUID[agentData.AgentID] = agentData; |
96 | } | 96 | } |
97 | } | 97 | } |
98 | } | 98 | } |
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 401551d..de8ecc2 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -3355,7 +3355,6 @@ namespace OpenSim.Region.Framework.Scenes | |||
3355 | /// </summary> | 3355 | /// </summary> |
3356 | public void RegisterCommsEvents() | 3356 | public void RegisterCommsEvents() |
3357 | { | 3357 | { |
3358 | m_sceneGridService.OnExpectUser += HandleNewUserConnection; | ||
3359 | m_sceneGridService.OnAvatarCrossingIntoRegion += AgentCrossing; | 3358 | m_sceneGridService.OnAvatarCrossingIntoRegion += AgentCrossing; |
3360 | m_sceneGridService.OnCloseAgentConnection += IncomingCloseAgent; | 3359 | m_sceneGridService.OnCloseAgentConnection += IncomingCloseAgent; |
3361 | //m_eventManager.OnRegionUp += OtherRegionUp; | 3360 | //m_eventManager.OnRegionUp += OtherRegionUp; |
@@ -3376,7 +3375,6 @@ namespace OpenSim.Region.Framework.Scenes | |||
3376 | //m_sceneGridService.OnRemoveKnownRegionFromAvatar -= HandleRemoveKnownRegionsFromAvatar; | 3375 | //m_sceneGridService.OnRemoveKnownRegionFromAvatar -= HandleRemoveKnownRegionsFromAvatar; |
3377 | //m_sceneGridService.OnChildAgentUpdate -= IncomingChildAgentDataUpdate; | 3376 | //m_sceneGridService.OnChildAgentUpdate -= IncomingChildAgentDataUpdate; |
3378 | //m_eventManager.OnRegionUp -= OtherRegionUp; | 3377 | //m_eventManager.OnRegionUp -= OtherRegionUp; |
3379 | m_sceneGridService.OnExpectUser -= HandleNewUserConnection; | ||
3380 | m_sceneGridService.OnAvatarCrossingIntoRegion -= AgentCrossing; | 3378 | m_sceneGridService.OnAvatarCrossingIntoRegion -= AgentCrossing; |
3381 | m_sceneGridService.OnCloseAgentConnection -= IncomingCloseAgent; | 3379 | m_sceneGridService.OnCloseAgentConnection -= IncomingCloseAgent; |
3382 | m_sceneGridService.OnGetLandData -= GetLandData; | 3380 | m_sceneGridService.OnGetLandData -= GetLandData; |
@@ -3388,22 +3386,6 @@ namespace OpenSim.Region.Framework.Scenes | |||
3388 | m_log.WarnFormat("[SCENE]: Deregister from grid failed for region {0}", m_regInfo.RegionName); | 3386 | m_log.WarnFormat("[SCENE]: Deregister from grid failed for region {0}", m_regInfo.RegionName); |
3389 | } | 3387 | } |
3390 | 3388 | ||
3391 | /// <summary> | ||
3392 | /// A handler for the SceneCommunicationService event, to match that events return type of void. | ||
3393 | /// Use NewUserConnection() directly if possible so the return type can refuse connections. | ||
3394 | /// At the moment nothing actually seems to use this event, | ||
3395 | /// as everything is switching to calling the NewUserConnection method directly. | ||
3396 | /// | ||
3397 | /// Now obsoleting this because it doesn't handle teleportFlags propertly | ||
3398 | /// | ||
3399 | /// </summary> | ||
3400 | /// <param name="agent"></param> | ||
3401 | [Obsolete("Please call NewUserConnection directly.")] | ||
3402 | public void HandleNewUserConnection(AgentCircuitData agent) | ||
3403 | { | ||
3404 | string reason; | ||
3405 | NewUserConnection(agent, 0, out reason); | ||
3406 | } | ||
3407 | 3389 | ||
3408 | /// <summary> | 3390 | /// <summary> |
3409 | /// Do the work necessary to initiate a new user connection for a particular scene. | 3391 | /// Do the work necessary to initiate a new user connection for a particular scene. |
@@ -3465,13 +3447,22 @@ namespace OpenSim.Region.Framework.Scenes | |||
3465 | ScenePresence sp = GetScenePresence(agent.AgentID); | 3447 | ScenePresence sp = GetScenePresence(agent.AgentID); |
3466 | if (sp != null) | 3448 | if (sp != null) |
3467 | { | 3449 | { |
3468 | m_log.DebugFormat( | 3450 | if (sp.IsChildAgent) |
3469 | "[SCENE]: Adjusting known seeds for existing agent {0} in {1}", | 3451 | { |
3470 | agent.AgentID, RegionInfo.RegionName); | 3452 | m_log.DebugFormat( |
3453 | "[SCENE]: Adjusting known seeds for existing agent {0} in {1}", | ||
3454 | agent.AgentID, RegionInfo.RegionName); | ||
3471 | 3455 | ||
3472 | sp.AdjustKnownSeeds(); | 3456 | sp.AdjustKnownSeeds(); |
3473 | 3457 | ||
3474 | return true; | 3458 | return true; |
3459 | } | ||
3460 | else | ||
3461 | { | ||
3462 | // We have a zombie from a crashed session. Kill it. | ||
3463 | m_log.DebugFormat("[SCENE]: Zombie scene presence detected for {0} in {1}", agent.AgentID, RegionInfo.RegionName); | ||
3464 | sp.ControllingClient.Close(); | ||
3465 | } | ||
3475 | } | 3466 | } |
3476 | 3467 | ||
3477 | CapsModule.AddCapsHandler(agent.AgentID); | 3468 | CapsModule.AddCapsHandler(agent.AgentID); |
diff --git a/OpenSim/Services/Connectors/Friends/FriendsSimConnector.cs b/OpenSim/Services/Connectors/Friends/FriendsSimConnector.cs index a29ac28..d7cb015 100644 --- a/OpenSim/Services/Connectors/Friends/FriendsSimConnector.cs +++ b/OpenSim/Services/Connectors/Friends/FriendsSimConnector.cs | |||
@@ -158,7 +158,7 @@ namespace OpenSim.Services.Connectors.Friends | |||
158 | } | 158 | } |
159 | catch (Exception e) | 159 | catch (Exception e) |
160 | { | 160 | { |
161 | m_log.DebugFormat("[FRIENDS CONNECTOR]: Exception when contacting remote sim: {0}", e.Message); | 161 | m_log.DebugFormat("[FRIENDS CONNECTOR]: Exception when contacting remote sim: {0}", e.ToString()); |
162 | } | 162 | } |
163 | 163 | ||
164 | return false; | 164 | return false; |
diff --git a/OpenSim/Services/InventoryService/XInventoryService.cs b/OpenSim/Services/InventoryService/XInventoryService.cs index 4d7103b..974caf0 100644 --- a/OpenSim/Services/InventoryService/XInventoryService.cs +++ b/OpenSim/Services/InventoryService/XInventoryService.cs | |||
@@ -386,7 +386,7 @@ namespace OpenSim.Services.InventoryService | |||
386 | XInventoryItem[] items = m_Database.GetActiveGestures(principalID); | 386 | XInventoryItem[] items = m_Database.GetActiveGestures(principalID); |
387 | 387 | ||
388 | if (items.Length == 0) | 388 | if (items.Length == 0) |
389 | return null; | 389 | return new List<InventoryItemBase>(); |
390 | 390 | ||
391 | List<InventoryItemBase> ret = new List<InventoryItemBase>(); | 391 | List<InventoryItemBase> ret = new List<InventoryItemBase>(); |
392 | 392 | ||
diff --git a/OpenSim/Services/LLLoginService/LLLoginResponse.cs b/OpenSim/Services/LLLoginService/LLLoginResponse.cs index d1dcfe7..54d53fb 100644 --- a/OpenSim/Services/LLLoginService/LLLoginResponse.cs +++ b/OpenSim/Services/LLLoginService/LLLoginResponse.cs | |||
@@ -217,12 +217,14 @@ namespace OpenSim.Services.LLLoginService | |||
217 | 217 | ||
218 | public LLLoginResponse(UserAccount account, AgentCircuitData aCircuit, GridUserInfo pinfo, | 218 | public LLLoginResponse(UserAccount account, AgentCircuitData aCircuit, GridUserInfo pinfo, |
219 | GridRegion destination, List<InventoryFolderBase> invSkel, FriendInfo[] friendsList, ILibraryService libService, | 219 | GridRegion destination, List<InventoryFolderBase> invSkel, FriendInfo[] friendsList, ILibraryService libService, |
220 | string where, string startlocation, Vector3 position, Vector3 lookAt, string message, | 220 | string where, string startlocation, Vector3 position, Vector3 lookAt, List<InventoryItemBase> gestures, string message, |
221 | GridRegion home, IPEndPoint clientIP) | 221 | GridRegion home, IPEndPoint clientIP) |
222 | : this() | 222 | : this() |
223 | { | 223 | { |
224 | FillOutInventoryData(invSkel, libService); | 224 | FillOutInventoryData(invSkel, libService); |
225 | 225 | ||
226 | FillOutActiveGestures(gestures); | ||
227 | |||
226 | CircuitCode = (int)aCircuit.circuitcode; | 228 | CircuitCode = (int)aCircuit.circuitcode; |
227 | Lastname = account.LastName; | 229 | Lastname = account.LastName; |
228 | Firstname = account.FirstName; | 230 | Firstname = account.FirstName; |
@@ -283,6 +285,22 @@ namespace OpenSim.Services.LLLoginService | |||
283 | } | 285 | } |
284 | } | 286 | } |
285 | 287 | ||
288 | private void FillOutActiveGestures(List<InventoryItemBase> gestures) | ||
289 | { | ||
290 | ArrayList list = new ArrayList(); | ||
291 | if (gestures != null) | ||
292 | { | ||
293 | foreach (InventoryItemBase gesture in gestures) | ||
294 | { | ||
295 | Hashtable item = new Hashtable(); | ||
296 | item["item_id"] = gesture.ID.ToString(); | ||
297 | item["asset_id"] = gesture.AssetID.ToString(); | ||
298 | list.Add(item); | ||
299 | } | ||
300 | } | ||
301 | ActiveGestures = list; | ||
302 | } | ||
303 | |||
286 | private void FillOutHomeData(GridUserInfo pinfo, GridRegion home) | 304 | private void FillOutHomeData(GridUserInfo pinfo, GridRegion home) |
287 | { | 305 | { |
288 | int x = 1000 * (int)Constants.RegionSize, y = 1000 * (int)Constants.RegionSize; | 306 | int x = 1000 * (int)Constants.RegionSize, y = 1000 * (int)Constants.RegionSize; |
diff --git a/OpenSim/Services/LLLoginService/LLLoginService.cs b/OpenSim/Services/LLLoginService/LLLoginService.cs index 9d151df..6319cc4 100644 --- a/OpenSim/Services/LLLoginService/LLLoginService.cs +++ b/OpenSim/Services/LLLoginService/LLLoginService.cs | |||
@@ -272,6 +272,10 @@ namespace OpenSim.Services.LLLoginService | |||
272 | return LLFailedLoginResponse.InventoryProblem; | 272 | return LLFailedLoginResponse.InventoryProblem; |
273 | } | 273 | } |
274 | 274 | ||
275 | // Get active gestures | ||
276 | List<InventoryItemBase> gestures = m_InventoryService.GetActiveGestures(account.PrincipalID); | ||
277 | m_log.DebugFormat("[LLOGIN SERVICE]: {0} active gestures", gestures.Count); | ||
278 | |||
275 | // | 279 | // |
276 | // Login the presence | 280 | // Login the presence |
277 | // | 281 | // |
@@ -350,7 +354,7 @@ namespace OpenSim.Services.LLLoginService | |||
350 | // Finally, fill out the response and return it | 354 | // Finally, fill out the response and return it |
351 | // | 355 | // |
352 | LLLoginResponse response = new LLLoginResponse(account, aCircuit, guinfo, destination, inventorySkel, friendsList, m_LibraryService, | 356 | LLLoginResponse response = new LLLoginResponse(account, aCircuit, guinfo, destination, inventorySkel, friendsList, m_LibraryService, |
353 | where, startLocation, position, lookAt, m_WelcomeMessage, home, clientIP); | 357 | where, startLocation, position, lookAt, gestures, m_WelcomeMessage, home, clientIP); |
354 | 358 | ||
355 | m_log.DebugFormat("[LLOGIN SERVICE]: All clear. Sending login response to client."); | 359 | m_log.DebugFormat("[LLOGIN SERVICE]: All clear. Sending login response to client."); |
356 | return response; | 360 | return response; |
@@ -746,8 +750,10 @@ namespace OpenSim.Services.LLLoginService | |||
746 | m_log.Debug("[LLOGIN SERVICE] Launching agent at " + destination.RegionName); | 750 | m_log.Debug("[LLOGIN SERVICE] Launching agent at " + destination.RegionName); |
747 | if (m_UserAgentService.LoginAgentToGrid(aCircuit, gatekeeper, destination, out reason)) | 751 | if (m_UserAgentService.LoginAgentToGrid(aCircuit, gatekeeper, destination, out reason)) |
748 | { | 752 | { |
749 | //IPAddress addr = NetworkUtil.GetIPFor(clientIP.Address, gatekeeper.ExternalEndPoint.Address); | 753 | // We may need to do this at some point, |
750 | m_UserAgentService.SetClientToken(aCircuit.SessionID, clientIP.Address.ToString()); | 754 | // so leaving it here in comments. |
755 | //IPAddress addr = NetworkUtil.GetIPFor(clientIP.Address, destination.ExternalEndPoint.Address); | ||
756 | m_UserAgentService.SetClientToken(aCircuit.SessionID, /*addr.Address.ToString() */ clientIP.Address.ToString()); | ||
751 | return true; | 757 | return true; |
752 | } | 758 | } |
753 | return false; | 759 | return false; |