diff options
author | Teravus Ovares (Dan Olivares) | 2009-09-14 16:30:36 -0400 |
---|---|---|
committer | Teravus Ovares (Dan Olivares) | 2009-09-14 16:30:36 -0400 |
commit | 1ad35f65b353a28a578c77ac62e72a5663107a8a (patch) | |
tree | a1945b99bc2cb3a9ba1a58941f50b77fcafb00f2 /OpenSim/Region/ScriptEngine | |
parent | * fix missing lock on XMLRPC GroupsModule (diff) | |
parent | Merge branch 'master' of ssh://diva@opensimulator.org/var/git/opensim (diff) | |
download | opensim-SC-1ad35f65b353a28a578c77ac62e72a5663107a8a.zip opensim-SC-1ad35f65b353a28a578c77ac62e72a5663107a8a.tar.gz opensim-SC-1ad35f65b353a28a578c77ac62e72a5663107a8a.tar.bz2 opensim-SC-1ad35f65b353a28a578c77ac62e72a5663107a8a.tar.xz |
Merge branch 'master' of ssh://MyConnection/var/git/opensim
Diffstat (limited to 'OpenSim/Region/ScriptEngine')
-rw-r--r-- | OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs b/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs index 04f7862..650d9fa 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs | |||
@@ -298,14 +298,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance | |||
298 | try | 298 | try |
299 | { | 299 | { |
300 | FileInfo fi = new FileInfo(savedState); | 300 | FileInfo fi = new FileInfo(savedState); |
301 | int size=(int)fi.Length; | 301 | int size = (int)fi.Length; |
302 | if (size < 512000) | 302 | if (size < 512000) |
303 | { | 303 | { |
304 | using (FileStream fs = File.Open(savedState, | 304 | using (FileStream fs = File.Open(savedState, |
305 | FileMode.Open, FileAccess.Read, FileShare.None)) | 305 | FileMode.Open, FileAccess.Read, FileShare.None)) |
306 | { | 306 | { |
307 | System.Text.ASCIIEncoding enc = | 307 | System.Text.UTF8Encoding enc = |
308 | new System.Text.ASCIIEncoding(); | 308 | new System.Text.UTF8Encoding(); |
309 | 309 | ||
310 | Byte[] data = new Byte[size]; | 310 | Byte[] data = new Byte[size]; |
311 | fs.Read(data, 0, size); | 311 | fs.Read(data, 0, size); |
@@ -899,7 +899,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance | |||
899 | try | 899 | try |
900 | { | 900 | { |
901 | FileStream fs = File.Create(Path.Combine(Path.GetDirectoryName(assembly), m_ItemID.ToString() + ".state")); | 901 | FileStream fs = File.Create(Path.Combine(Path.GetDirectoryName(assembly), m_ItemID.ToString() + ".state")); |
902 | System.Text.ASCIIEncoding enc = new System.Text.ASCIIEncoding(); | 902 | System.Text.UTF8Encoding enc = new System.Text.UTF8Encoding(); |
903 | Byte[] buf = enc.GetBytes(xml); | 903 | Byte[] buf = enc.GetBytes(xml); |
904 | fs.Write(buf, 0, buf.Length); | 904 | fs.Write(buf, 0, buf.Length); |
905 | fs.Close(); | 905 | fs.Close(); |