aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
diff options
context:
space:
mode:
authorMelanie2009-12-14 00:40:56 +0000
committerMelanie2009-12-14 00:40:56 +0000
commit824d7190c2a5520f1cf6f3d24585b8c47c841e55 (patch)
tree0814d0228121249b7f2a33658180a0a446d13f51 /OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
parentAnd reverse (diff)
parentMerge branch 'master' of melanie@opensimulator.org:/var/git/opensim (diff)
downloadopensim-SC-824d7190c2a5520f1cf6f3d24585b8c47c841e55.zip
opensim-SC-824d7190c2a5520f1cf6f3d24585b8c47c841e55.tar.gz
opensim-SC-824d7190c2a5520f1cf6f3d24585b8c47c841e55.tar.bz2
opensim-SC-824d7190c2a5520f1cf6f3d24585b8c47c841e55.tar.xz
Merge branch 'master' into careminster
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs14
1 files changed, 14 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
index 836f276..d7480e6 100644
--- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs
@@ -1973,5 +1973,19 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
1973 } 1973 }
1974 return ret; 1974 return ret;
1975 } 1975 }
1976
1977 public int osGetSimulatorMemory()
1978 {
1979 CheckThreatLevel(ThreatLevel.Moderate, "osGetSimulatorMemory");
1980 m_host.AddScriptLPS(1);
1981 long pws = System.Diagnostics.Process.GetCurrentProcess().WorkingSet64;
1982
1983 if (pws > Int32.MaxValue)
1984 return Int32.MaxValue;
1985 if (pws < 0)
1986 return 0;
1987
1988 return (int)pws;
1989 }
1976 } 1990 }
1977} 1991}