From 30ac67fb3d10c0cdeb82bb995b579986a4fed528 Mon Sep 17 00:00:00 2001 From: "Justin Clark-Casey (justincc)" Date: Tue, 27 Jul 2010 20:15:43 +0100 Subject: [PATCH] make MoapModule ignore possible future media texture data that it can't handle --- OpenSim/Region/CoreModules/World/Media/Moap/MoapModule.cs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/OpenSim/Region/CoreModules/World/Media/Moap/MoapModule.cs b/OpenSim/Region/CoreModules/World/Media/Moap/MoapModule.cs index 81e4449b40..3a86167930 100644 --- a/OpenSim/Region/CoreModules/World/Media/Moap/MoapModule.cs +++ b/OpenSim/Region/CoreModules/World/Media/Moap/MoapModule.cs @@ -60,6 +60,8 @@ namespace OpenSim.Region.CoreModules.Media.Moap public string Name { get { return "MoapModule"; } } public Type ReplaceableInterface { get { return null; } } + public const string MEDIA_TEXTURE_TYPE = "sl"; + /// /// Is this module enabled? /// @@ -206,7 +208,7 @@ namespace OpenSim.Region.CoreModules.Media.Moap string type = xtr.GetAttribute("type"); //m_log.DebugFormat("[MOAP]: Loaded media texture entry with type {0}", type); - if (type != "sl") + if (type != MEDIA_TEXTURE_TYPE) return; xtr.ReadStartElement("osmedia"); @@ -237,7 +239,7 @@ namespace OpenSim.Region.CoreModules.Media.Moap using (XmlTextWriter xtw = new XmlTextWriter(sw)) { xtw.WriteStartElement("osmedia"); - xtw.WriteAttributeString("type", "sl"); + xtw.WriteAttributeString("type", MEDIA_TEXTURE_TYPE); xtw.WriteAttributeString("major_version", "0"); xtw.WriteAttributeString("minor_version", "1");