diff options
author | John Hurliman | 2009-09-01 12:07:48 -0700 |
---|---|---|
committer | Diva Canto | 2009-09-03 12:36:51 -0700 |
commit | 33133e23b12781e71b499fcaa41bcad6374c6656 (patch) | |
tree | bc94accc274e9b319b9cca9f5194bc9ddcbff471 /OpenSim/Region | |
parent | Added Util.FireAndForget(), to replace leaking calls to Delegate.BeginInvoke() (diff) | |
download | opensim-SC_OLD-33133e23b12781e71b499fcaa41bcad6374c6656.zip opensim-SC_OLD-33133e23b12781e71b499fcaa41bcad6374c6656.tar.gz opensim-SC_OLD-33133e23b12781e71b499fcaa41bcad6374c6656.tar.bz2 opensim-SC_OLD-33133e23b12781e71b499fcaa41bcad6374c6656.tar.xz |
Fixes seven leaky .BeginInvoke() calls
Diffstat (limited to 'OpenSim/Region')
3 files changed, 8 insertions, 4 deletions
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/HGAssetBroker.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/HGAssetBroker.cs index 621e9d2..7b4e374 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/HGAssetBroker.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/HGAssetBroker.cs | |||
@@ -272,7 +272,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Asset | |||
272 | 272 | ||
273 | if (asset != null) | 273 | if (asset != null) |
274 | { | 274 | { |
275 | handler.BeginInvoke(id, sender, asset, null, null); | 275 | Util.FireAndForget(delegate { handler(id, sender, asset); }); |
276 | return true; | 276 | return true; |
277 | } | 277 | } |
278 | 278 | ||
diff --git a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/LocalAssetServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/LocalAssetServiceConnector.cs index b13a116..fd3aaf4 100644 --- a/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/LocalAssetServiceConnector.cs +++ b/OpenSim/Region/CoreModules/ServiceConnectorsOut/Asset/LocalAssetServiceConnector.cs | |||
@@ -211,7 +211,7 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Asset | |||
211 | 211 | ||
212 | if (asset != null) | 212 | if (asset != null) |
213 | { | 213 | { |
214 | handler.BeginInvoke(id, sender, asset, null, null); | 214 | Util.FireAndForget(delegate { handler(id, sender, asset); }); |
215 | return true; | 215 | return true; |
216 | } | 216 | } |
217 | 217 | ||
@@ -219,8 +219,8 @@ namespace OpenSim.Region.CoreModules.ServiceConnectorsOut.Asset | |||
219 | { | 219 | { |
220 | if ((a != null) && (m_Cache != null)) | 220 | if ((a != null) && (m_Cache != null)) |
221 | m_Cache.Cache(a); | 221 | m_Cache.Cache(a); |
222 | 222 | ||
223 | handler.BeginInvoke(assetID, s, a, null, null); | 223 | Util.FireAndForget(delegate { handler(assetID, s, a); }); |
224 | }); | 224 | }); |
225 | } | 225 | } |
226 | 226 | ||
diff --git a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs index 55b100b..fddba86 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.PacketHandlers.cs | |||
@@ -457,6 +457,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
457 | 457 | ||
458 | void SendInventoryComplete(IAsyncResult iar) | 458 | void SendInventoryComplete(IAsyncResult iar) |
459 | { | 459 | { |
460 | SendInventoryDelegate d = (SendInventoryDelegate)iar.AsyncState; | ||
461 | d.EndInvoke(iar); | ||
460 | } | 462 | } |
461 | 463 | ||
462 | /// <summary> | 464 | /// <summary> |
@@ -622,6 +624,8 @@ namespace OpenSim.Region.Framework.Scenes | |||
622 | 624 | ||
623 | private void PurgeFolderCompleted(IAsyncResult iar) | 625 | private void PurgeFolderCompleted(IAsyncResult iar) |
624 | { | 626 | { |
627 | PurgeFolderDelegate d = (PurgeFolderDelegate)iar.AsyncState; | ||
628 | d.EndInvoke(iar); | ||
625 | } | 629 | } |
626 | } | 630 | } |
627 | } | 631 | } |