From b2ed348aa2746fbf034b713d006e40366c479d5a Mon Sep 17 00:00:00 2001 From: John Hurliman Date: Thu, 22 Oct 2009 12:33:23 -0700 Subject: Implemented a Watchdog class. Do not manually create Thread objects anymore, use Watchdog.StartThread(). While your thread is running call Watchdog.UpdateThread(). When it is shutting down call Watchdog.RemoveThread(). Most of the threads in OpenSim have been updated --- OpenSim/Region/CoreModules/World/Archiver/AssetsRequest.cs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'OpenSim/Region/CoreModules/World/Archiver') diff --git a/OpenSim/Region/CoreModules/World/Archiver/AssetsRequest.cs b/OpenSim/Region/CoreModules/World/Archiver/AssetsRequest.cs index fe9c8d9..c9fce91 100644 --- a/OpenSim/Region/CoreModules/World/Archiver/AssetsRequest.cs +++ b/OpenSim/Region/CoreModules/World/Archiver/AssetsRequest.cs @@ -128,7 +128,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver if (m_repliesRequired == 0) { m_requestState = RequestState.Completed; - PerformAssetsRequestCallback(); + PerformAssetsRequestCallback(null); return; } @@ -246,9 +246,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver // We want to stop using the asset cache thread asap // as we now need to do the work of producing the rest of the archive - Thread newThread = new Thread(PerformAssetsRequestCallback); - newThread.Name = "OpenSimulator archiving thread post assets receipt"; - newThread.Start(); + Util.FireAndForget(PerformAssetsRequestCallback); } else { @@ -265,7 +263,7 @@ namespace OpenSim.Region.CoreModules.World.Archiver /// /// Perform the callback on the original requester of the assets /// - protected void PerformAssetsRequestCallback() + protected void PerformAssetsRequestCallback(object o) { try { -- cgit v1.1