From a53cc8fbfad92d050fce30dceca88c6749cfa24e Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Sat, 26 Apr 2008 06:56:50 +0000 Subject: * Error on System. references with 'CS20003: 'System' is null or not an object" --- .../Region/ScriptEngine/DotNetEngine/Compiler/LSL/LSL2CSConverter.cs | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'OpenSim') diff --git a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/LSL2CSConverter.cs b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/LSL2CSConverter.cs index a766ea2..fa91544 100644 --- a/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/LSL2CSConverter.cs +++ b/OpenSim/Region/ScriptEngine/DotNetEngine/Compiler/LSL/LSL2CSConverter.cs @@ -85,6 +85,11 @@ namespace OpenSim.Region.ScriptEngine.DotNetEngine.Compiler.LSL string quote = String.Empty; bool last_was_escape = false; int quote_replaced_count = 0; + + Match SecurityM = Regex.Match(Script, "[;}][^\"']+System\\.[^\"']", RegexOptions.Compiled | RegexOptions.Multiline | RegexOptions.Singleline | RegexOptions.IgnoreCase); + if (SecurityM.Success) + throw new Exception("BC20002: 'System' is null or not an object"); + for (int p = 0; p < Script.Length; p++) { C = Script.Substring(p, 1); -- cgit v1.1