From c605509da3a690d4050c48418111d7f29f7be9b4 Mon Sep 17 00:00:00 2001 From: Teravus Ovares (Dan Olivares) Date: Wed, 9 Sep 2009 16:20:19 -0400 Subject: * Lock timers when Calling Start() and Stop() when the Thread Context is murky. This affects Mono only. --- OpenSim/Client/MXP/MXPModule.cs | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'OpenSim/Client') diff --git a/OpenSim/Client/MXP/MXPModule.cs b/OpenSim/Client/MXP/MXPModule.cs index dbe4174..2d28b8c 100644 --- a/OpenSim/Client/MXP/MXPModule.cs +++ b/OpenSim/Client/MXP/MXPModule.cs @@ -81,7 +81,8 @@ namespace OpenSim.Client.MXP m_ticker.AutoReset = false; m_ticker.Elapsed += ticker_Elapsed; - m_ticker.Start(); + lock (m_ticker) + m_ticker.Start(); m_log.Info("[MXP ClientStack] MXP Enabled and Listening"); } @@ -99,13 +100,17 @@ namespace OpenSim.Client.MXP } if (!m_shutdown) - m_ticker.Start(); + { + lock (m_ticker) + m_ticker.Start(); + } } public void Close() { m_shutdown = true; - m_ticker.Stop(); + lock (m_ticker) + m_ticker.Stop(); } public string Name -- cgit v1.1