aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Serialization/CoalescedSceneObjectsSerializer.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2012-05-23 01:58:10 +0100
committerJustin Clark-Casey (justincc)2012-05-23 01:58:10 +0100
commitff429a259b41f1205a6b153bb6da383d9a9f5daf (patch)
tree70d7a495cc6d846ef593f8bb0ed608c31b78f079 /OpenSim/Region/Framework/Scenes/Serialization/CoalescedSceneObjectsSerializer.cs
parentSetting 'in transit' on a local teleport as well as inter-region teleports. (diff)
downloadopensim-SC_OLD-ff429a259b41f1205a6b153bb6da383d9a9f5daf.zip
opensim-SC_OLD-ff429a259b41f1205a6b153bb6da383d9a9f5daf.tar.gz
opensim-SC_OLD-ff429a259b41f1205a6b153bb6da383d9a9f5daf.tar.bz2
opensim-SC_OLD-ff429a259b41f1205a6b153bb6da383d9a9f5daf.tar.xz
Fix bug where an avatar that had an object they owned attached through llAttachToAvatar() or osForceAttachToAvatar() would wrongly have next permissions come into play when they detached that object and rezzed it in scene.
This is because the attachments module code was setting the 'object slam' bit by using PermissionMask.All Solution here is to route the attachment item creation call through the existing inventory code in BasicInventoryAccessModule rather than copy/pasted code in AttachmentsModule itself.
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Framework/Scenes/Serialization/CoalescedSceneObjectsSerializer.cs20
1 files changed, 18 insertions, 2 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Serialization/CoalescedSceneObjectsSerializer.cs b/OpenSim/Region/Framework/Scenes/Serialization/CoalescedSceneObjectsSerializer.cs
index 55455cc..a4f730d 100644
--- a/OpenSim/Region/Framework/Scenes/Serialization/CoalescedSceneObjectsSerializer.cs
+++ b/OpenSim/Region/Framework/Scenes/Serialization/CoalescedSceneObjectsSerializer.cs
@@ -47,14 +47,30 @@ namespace OpenSim.Region.Framework.Scenes.Serialization
47 /// </remarks> 47 /// </remarks>
48 public class CoalescedSceneObjectsSerializer 48 public class CoalescedSceneObjectsSerializer
49 { 49 {
50 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 50 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
51 51
52 /// <summary> 52 /// <summary>
53 /// Serialize coalesced objects to Xml 53 /// Serialize coalesced objects to Xml
54 /// </summary> 54 /// </summary>
55 /// <param name="coa"></param> 55 /// <param name="coa"></param>
56 /// <param name="doScriptStates">
57 /// If true then serialize script states. This will halt any running scripts
58 /// </param>
56 /// <returns></returns> 59 /// <returns></returns>
57 public static string ToXml(CoalescedSceneObjects coa) 60 public static string ToXml(CoalescedSceneObjects coa)
61 {
62 return ToXml(coa, true);
63 }
64
65 /// <summary>
66 /// Serialize coalesced objects to Xml
67 /// </summary>
68 /// <param name="coa"></param>
69 /// <param name="doScriptStates">
70 /// If true then serialize script states. This will halt any running scripts
71 /// </param>
72 /// <returns></returns>
73 public static string ToXml(CoalescedSceneObjects coa, bool doScriptStates)
58 { 74 {
59 using (StringWriter sw = new StringWriter()) 75 using (StringWriter sw = new StringWriter())
60 { 76 {
@@ -91,7 +107,7 @@ namespace OpenSim.Region.Framework.Scenes.Serialization
91 writer.WriteAttributeString("offsety", offsets[i].Y.ToString()); 107 writer.WriteAttributeString("offsety", offsets[i].Y.ToString());
92 writer.WriteAttributeString("offsetz", offsets[i].Z.ToString()); 108 writer.WriteAttributeString("offsetz", offsets[i].Z.ToString());
93 109
94 SceneObjectSerializer.ToOriginalXmlFormat(obj, writer, true); 110 SceneObjectSerializer.ToOriginalXmlFormat(obj, writer, doScriptStates);
95 111
96 writer.WriteEndElement(); // SceneObjectGroup 112 writer.WriteEndElement(); // SceneObjectGroup
97 } 113 }