aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim')
-rw-r--r--OpenSim/Region/Communications/Local/LocalLoginService.cs25
-rw-r--r--OpenSim/Region/Environment/Scenes/Scene.cs1
2 files changed, 25 insertions, 1 deletions
diff --git a/OpenSim/Region/Communications/Local/LocalLoginService.cs b/OpenSim/Region/Communications/Local/LocalLoginService.cs
index 9b71efd..e139501 100644
--- a/OpenSim/Region/Communications/Local/LocalLoginService.cs
+++ b/OpenSim/Region/Communications/Local/LocalLoginService.cs
@@ -57,7 +57,7 @@ namespace OpenSim.Region.Communications.Local
57 /// <summary> 57 /// <summary>
58 /// Used to make requests to the local regions. 58 /// Used to make requests to the local regions.
59 /// </summary> 59 /// </summary>
60 protected IGridServices m_gridService; 60 protected LocalBackEndServices m_gridService;
61 61
62 public event LoginToRegionEvent OnLoginToRegion; 62 public event LoginToRegionEvent OnLoginToRegion;
63 63
@@ -376,5 +376,28 @@ namespace OpenSim.Region.Communications.Local
376 376
377 return new InventoryData(AgentInventoryArray, rootID); 377 return new InventoryData(AgentInventoryArray, rootID);
378 } 378 }
379
380 public override void LogOffUser(UserProfileData theUser, string message)
381 {
382 RegionInfo SimInfo;
383 try
384 {
385 SimInfo = this.m_gridService.RequestNeighbourInfo(theUser.CurrentAgent.Handle);
386
387 if (SimInfo == null)
388 {
389 m_log.Error("[LOCAL LOGIN]: Region user was in isn't currently logged in");
390 return;
391 }
392 }
393 catch (Exception)
394 {
395 m_log.Error("[LOCAL LOGIN]: Unable to look up region to log user off");
396 return;
397 }
398
399 m_gridService.TriggerLogOffUser(SimInfo.RegionHandle, theUser.ID, theUser.CurrentAgent.SecureSessionID, "Logging you off");
400 }
401
379 } 402 }
380} 403}
diff --git a/OpenSim/Region/Environment/Scenes/Scene.cs b/OpenSim/Region/Environment/Scenes/Scene.cs
index 6831885..3aa2470 100644
--- a/OpenSim/Region/Environment/Scenes/Scene.cs
+++ b/OpenSim/Region/Environment/Scenes/Scene.cs
@@ -2946,6 +2946,7 @@ namespace OpenSim.Region.Environment.Scenes
2946 { 2946 {
2947 if (RegionSecret == loggingOffUser.ControllingClient.SecureSessionId) 2947 if (RegionSecret == loggingOffUser.ControllingClient.SecureSessionId)
2948 { 2948 {
2949 m_sceneGridService.SendCloseChildAgentConnections(loggingOffUser.UUID, new List<ulong>(loggingOffUser.KnownRegions.Keys));
2949 loggingOffUser.ControllingClient.Kick(message); 2950 loggingOffUser.ControllingClient.Kick(message);
2950 // Give them a second to receive the message! 2951 // Give them a second to receive the message!
2951 System.Threading.Thread.Sleep(1000); 2952 System.Threading.Thread.Sleep(1000);