diff options
author | Justin Clark-Casey (justincc) | 2015-01-26 23:16:06 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2015-01-26 23:31:46 +0000 |
commit | 1bed3aff0b21102f04481b2345a0d804c2e5716c (patch) | |
tree | 36c9b6fb997849ca0831e690d9c4b210789b680b /OpenSim/Region/ScriptEngine/Shared/CodeTools | |
parent | BulletSim: update DLLs, SOs, and dylib with latest versions. (diff) | |
download | opensim-SC-1bed3aff0b21102f04481b2345a0d804c2e5716c.zip opensim-SC-1bed3aff0b21102f04481b2345a0d804c2e5716c.tar.gz opensim-SC-1bed3aff0b21102f04481b2345a0d804c2e5716c.tar.bz2 opensim-SC-1bed3aff0b21102f04481b2345a0d804c2e5716c.tar.xz |
On a multi-region simulator when AppDomain = true, make sure the DLL from the appropriate script engines subdir is loaded rather than always that of the first engine to load the DLL.
This resolves a DLL load failure on my Linux box when an attachment script was present on another region before the avatar arrived.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs index 52a34a6..af324bf 100644 --- a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs +++ b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs | |||
@@ -291,7 +291,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | |||
291 | string source, string asset, UUID ownerUUID, bool alwaysRecompile, | 291 | string source, string asset, UUID ownerUUID, bool alwaysRecompile, |
292 | out string assembly, out Dictionary<KeyValuePair<int, int>, KeyValuePair<int, int>> linemap) | 292 | out string assembly, out Dictionary<KeyValuePair<int, int>, KeyValuePair<int, int>> linemap) |
293 | { | 293 | { |
294 | // m_log.DebugFormat("[Compiler]: Compiling script\n{0}", Script); | 294 | // m_log.DebugFormat("[Compiler]: Checking script for asset {0} in {1}\n{2}", asset, m_scriptEngine.World.Name, source); |
295 | 295 | ||
296 | IScriptModuleComms comms = m_scriptEngine.World.RequestModuleInterface<IScriptModuleComms>(); | 296 | IScriptModuleComms comms = m_scriptEngine.World.RequestModuleInterface<IScriptModuleComms>(); |
297 | 297 | ||
@@ -300,12 +300,16 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | |||
300 | 300 | ||
301 | assembly = GetCompilerOutput(asset); | 301 | assembly = GetCompilerOutput(asset); |
302 | 302 | ||
303 | // m_log.DebugFormat("[Compiler]: Retrieved assembly {0} for asset {1} in {2}", assembly, asset, m_scriptEngine.World.Name); | ||
304 | |||
303 | CheckOrCreateScriptsDirectory(); | 305 | CheckOrCreateScriptsDirectory(); |
304 | 306 | ||
305 | // Don't recompile if we're not forced to and we already have it | 307 | // Don't recompile if we're not forced to and we already have it |
306 | // Performing 3 file exists tests for every script can still be slow | 308 | // Performing 3 file exists tests for every script can still be slow |
307 | if (!alwaysRecompile && File.Exists(assembly) && File.Exists(assembly + ".text") && File.Exists(assembly + ".map")) | 309 | if (!alwaysRecompile && File.Exists(assembly) && File.Exists(assembly + ".text") && File.Exists(assembly + ".map")) |
308 | { | 310 | { |
311 | // m_log.DebugFormat("[Compiler]: Found existing assembly {0} for asset {1} in {2}", assembly, asset, m_scriptEngine.World.Name); | ||
312 | |||
309 | // If we have already read this linemap file, then it will be in our dictionary. | 313 | // If we have already read this linemap file, then it will be in our dictionary. |
310 | // Don't build another copy of the dictionary (saves memory) and certainly | 314 | // Don't build another copy of the dictionary (saves memory) and certainly |
311 | // don't keep reading the same file from disk multiple times. | 315 | // don't keep reading the same file from disk multiple times. |
@@ -315,6 +319,8 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools | |||
315 | return; | 319 | return; |
316 | } | 320 | } |
317 | 321 | ||
322 | // m_log.DebugFormat("[Compiler]: Compiling assembly {0} for asset {1} in {2}", assembly, asset, m_scriptEngine.World.Name); | ||
323 | |||
318 | if (source == String.Empty) | 324 | if (source == String.Empty) |
319 | throw new Exception("Cannot find script assembly and no script text present"); | 325 | throw new Exception("Cannot find script assembly and no script text present"); |
320 | 326 | ||