diff options
author | diva | 2008-12-17 17:44:00 +0000 |
---|---|---|
committer | diva | 2008-12-17 17:44:00 +0000 |
commit | 7b6471f642a9fdc9c7835f15495017e351aff48b (patch) | |
tree | de741ee73a1f084fc1428729e7c69f9f23106a63 | |
parent | * Only serialize packets once for the length calculation for throttle queues ... (diff) | |
download | opensim-SC_OLD-7b6471f642a9fdc9c7835f15495017e351aff48b.zip opensim-SC_OLD-7b6471f642a9fdc9c7835f15495017e351aff48b.tar.gz opensim-SC_OLD-7b6471f642a9fdc9c7835f15495017e351aff48b.tar.bz2 opensim-SC_OLD-7b6471f642a9fdc9c7835f15495017e351aff48b.tar.xz |
Kicking child agents off on the first login after a client crash. The child agents kickoff was
missing from when this is run in grid mode. But, worse, turns out that this whole feature of kicking
off the user after a crash was entirely missing from standalone mode.
-rw-r--r-- | OpenSim/Region/Communications/Local/LocalLoginService.cs | 25 | ||||
-rw-r--r-- | OpenSim/Region/Environment/Scenes/Scene.cs | 1 |
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); |