aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs10
1 files changed, 9 insertions, 1 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs
index fcb3339..911da5b 100644
--- a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Compiler.cs
@@ -37,6 +37,7 @@ using Microsoft.VisualBasic;
37using log4net; 37using log4net;
38using OpenSim.Region.Framework.Interfaces; 38using OpenSim.Region.Framework.Interfaces;
39using OpenSim.Region.ScriptEngine.Interfaces; 39using OpenSim.Region.ScriptEngine.Interfaces;
40using OpenMetaverse;
40 41
41namespace OpenSim.Region.ScriptEngine.Shared.CodeTools 42namespace OpenSim.Region.ScriptEngine.Shared.CodeTools
42{ 43{
@@ -263,7 +264,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools
263 /// </summary> 264 /// </summary>
264 /// <param name="Script">LSL script</param> 265 /// <param name="Script">LSL script</param>
265 /// <returns>Filename to .dll assembly</returns> 266 /// <returns>Filename to .dll assembly</returns>
266 public string PerformScriptCompile(string Script, string asset) 267 public string PerformScriptCompile(string Script, string asset, UUID ownerUUID)
267 { 268 {
268 m_positionMap = null; 269 m_positionMap = null;
269 m_warnings.Clear(); 270 m_warnings.Clear();
@@ -341,6 +342,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.CodeTools
341 throw new Exception(errtext); 342 throw new Exception(errtext);
342 } 343 }
343 344
345 if(m_scriptEngine.World.Permissions.CanCompileScript(ownerUUID, (int)l) == false) {
346 // Not allowed to compile to this language!
347 string errtext = String.Empty;
348 errtext += ownerUUID + " is not in list of allowed users for this scripting language. Script will not be executed!";
349 throw new Exception(errtext);
350 }
351
344 string compileScript = Script; 352 string compileScript = Script;
345 353
346 if (l == enumCompileType.lsl) 354 if (l == enumCompileType.lsl)