From 747c25e92083c6a71b4163a9336c91cffa67bfb2 Mon Sep 17 00:00:00 2001 From: Melanie Date: Tue, 17 Jan 2012 11:18:56 +0100 Subject: Spin off NPC deletion into a thread to avoid it being done on a script microthread. A stab at fixing exceptions. --- OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/ScriptEngine/Shared/Api') diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index ca340c6..37792ef 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs @@ -2406,7 +2406,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api if (!module.CheckPermissions(npcId, m_host.OwnerID)) return; - module.DeleteNPC(npcId, World); + Util.FireAndForget(delegate(object x) { + module.DeleteNPC(npcId, World); + }); } } -- cgit v1.1