diff options
author | onefang | 2019-09-11 22:36:30 +1000 |
---|---|---|
committer | onefang | 2019-09-11 22:36:30 +1000 |
commit | bfce5d75d5923272e901581bd7e5a1355db7bd0e (patch) | |
tree | 0cfa3f69393c101cc64d4360fa18018c6d6e087c /OpenSim/Region/ScriptEngine/Shared | |
parent | NEWS++ (diff) | |
download | opensim-SC-bfce5d75d5923272e901581bd7e5a1355db7bd0e.zip opensim-SC-bfce5d75d5923272e901581bd7e5a1355db7bd0e.tar.gz opensim-SC-bfce5d75d5923272e901581bd7e5a1355db7bd0e.tar.bz2 opensim-SC-bfce5d75d5923272e901581bd7e5a1355db7bd0e.tar.xz |
Hack around some tests failing.OpenSim_SC_0.9.0.1_1
Fix the tests later.
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | 25 |
1 files changed, 16 insertions, 9 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index a8c1a8f..fb58850 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | |||
@@ -274,15 +274,22 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
274 | // or a string explaining why this function can't be used. | 274 | // or a string explaining why this function can't be used. |
275 | private string CheckThreatLevelTest(ThreatLevel level, string function) | 275 | private string CheckThreatLevelTest(ThreatLevel level, string function) |
276 | { | 276 | { |
277 | // Grid gods can do anything they damn well please. | 277 | // This test is coz the test system manages to call scripts without having them in items. |
278 | if (World.Permissions.IsGridGod(m_item.OwnerID)) | 278 | //// TODO - fix up the test system. |
279 | return String.Empty; | 279 | if ((null != m_item) && (null != m_item.OwnerID)) |
280 | else | 280 | { |
281 | { | 281 | // Grid gods can do anything they damn well please. |
282 | // So can active gods. | 282 | if (World.Permissions.IsGridGod(m_item.OwnerID)) |
283 | ScenePresence sp = World.GetScenePresence(m_item.OwnerID); | 283 | { |
284 | if (sp != null && !sp.IsDeleted && sp.IsGod) | 284 | return String.Empty; |
285 | return String.Empty; | 285 | } |
286 | else | ||
287 | { | ||
288 | // So can active gods. | ||
289 | ScenePresence sp = World.GetScenePresence(m_item.OwnerID); | ||
290 | if (sp != null && !sp.IsDeleted && sp.IsGod) | ||
291 | return String.Empty; | ||
292 | } | ||
286 | } | 293 | } |
287 | 294 | ||
288 | if (!m_FunctionPerms.ContainsKey(function)) | 295 | if (!m_FunctionPerms.ContainsKey(function)) |