From 4c7da1421fcdec59de487bb5744d545b3fbed7c0 Mon Sep 17 00:00:00 2001 From: Dr Scofield Date: Wed, 20 May 2009 13:37:25 +0000 Subject: [PATCH] refactoring instantiation of Location object: moving it out of the for loop as it really is a "constant" --- OpenSim/Region/Application/OpenSimBase.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/OpenSim/Region/Application/OpenSimBase.cs b/OpenSim/Region/Application/OpenSimBase.cs index 14ae5f165f..eaf6e4f0bc 100644 --- a/OpenSim/Region/Application/OpenSimBase.cs +++ b/OpenSim/Region/Application/OpenSimBase.cs @@ -604,10 +604,11 @@ namespace OpenSim // Shutting down the client server bool foundClientServer = false; int clientServerElement = 0; + Location location = new Location(whichRegion.RegionHandle); for (int i = 0; i < m_clientServers.Count; i++) { - if (m_clientServers[i].HandlesRegion(new Location(whichRegion.RegionHandle))) + if (m_clientServers[i].HandlesRegion(location)) { clientServerElement = i; foundClientServer = true;