Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAtsushi Eno <atsushieno@gmail.com>2007-02-01 22:56:56 +0300
committerAtsushi Eno <atsushieno@gmail.com>2007-02-01 22:56:56 +0300
commit91265f5bcbca13185e739e2fa65fd07036733b49 (patch)
tree5f6a8672b90b74bedf1a3b89cb6d68211464cc8b /mcs/class/System.XML/Mono.Xml.XPath
parente030ef95c471a2645facde7b918f7b5eff2ded27 (diff)
2007-02-01 Atsushi Enomoto <atsushi@ximian.com>
* DTMXPathDocumentWriter2.cs : supply prefix when it was not passed. svn path=/trunk/mcs/; revision=72128
Diffstat (limited to 'mcs/class/System.XML/Mono.Xml.XPath')
-rw-r--r--mcs/class/System.XML/Mono.Xml.XPath/ChangeLog4
-rw-r--r--mcs/class/System.XML/Mono.Xml.XPath/DTMXPathDocumentWriter2.cs8
2 files changed, 10 insertions, 2 deletions
diff --git a/mcs/class/System.XML/Mono.Xml.XPath/ChangeLog b/mcs/class/System.XML/Mono.Xml.XPath/ChangeLog
index c9f2b7ff967..724727e4501 100644
--- a/mcs/class/System.XML/Mono.Xml.XPath/ChangeLog
+++ b/mcs/class/System.XML/Mono.Xml.XPath/ChangeLog
@@ -1,3 +1,7 @@
+2007-02-01 Atsushi Enomoto <atsushi@ximian.com>
+
+ * DTMXPathDocumentWriter2.cs : supply prefix when it was not passed.
+
2007-01-31 Atsushi Enomoto <atsushi@ximian.com>
* DTMXPathNavigator2.cs : cosmetic performance improvement.
diff --git a/mcs/class/System.XML/Mono.Xml.XPath/DTMXPathDocumentWriter2.cs b/mcs/class/System.XML/Mono.Xml.XPath/DTMXPathDocumentWriter2.cs
index b4f7414964d..42f2a4990c2 100644
--- a/mcs/class/System.XML/Mono.Xml.XPath/DTMXPathDocumentWriter2.cs
+++ b/mcs/class/System.XML/Mono.Xml.XPath/DTMXPathDocumentWriter2.cs
@@ -525,10 +525,12 @@ namespace Mono.Xml.XPath
public override void WriteStartElement (string prefix, string localName, string ns)
{
- if (prefix == null)
- prefix = String.Empty;
if (ns == null)
ns = String.Empty;
+ else if (prefix == null && ns.Length > 0)
+ prefix = LookupPrefix (ns);
+ if (prefix == null)
+ prefix = String.Empty;
switch (state) {
case WriteState.Element:
@@ -640,6 +642,8 @@ namespace Mono.Xml.XPath
private void ProcessAttribute (string prefix, string localName, string ns, string value)
{
+ if (prefix == null && ns.Length > 0)
+ prefix = LookupPrefix (ns);
attributeIndex ++;
this.AddAttribute (nodeIndex,