You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@santuario.apache.org by gi...@apache.org on 2014/08/26 20:56:01 UTC
svn commit: r1620695 -
/santuario/xml-security-java/trunk/src/main/java/org/apache/jcp/xml/dsig/internal/dom/XmlWriterToTree.java
Author: giger
Date: Tue Aug 26 18:56:00 2014
New Revision: 1620695
URL: http://svn.apache.org/r1620695
Log:
WSS-508 - The node passed to appendChild() may not be the same as the internally appended one. This depends on the DOM implementation and is the reason why the method returns the new appended node. So correctly reassign the returned node.
Modified:
santuario/xml-security-java/trunk/src/main/java/org/apache/jcp/xml/dsig/internal/dom/XmlWriterToTree.java
Modified: santuario/xml-security-java/trunk/src/main/java/org/apache/jcp/xml/dsig/internal/dom/XmlWriterToTree.java
URL: http://svn.apache.org/viewvc/santuario/xml-security-java/trunk/src/main/java/org/apache/jcp/xml/dsig/internal/dom/XmlWriterToTree.java?rev=1620695&r1=1620694&r2=1620695&view=diff
==============================================================================
--- santuario/xml-security-java/trunk/src/main/java/org/apache/jcp/xml/dsig/internal/dom/XmlWriterToTree.java (original)
+++ santuario/xml-security-java/trunk/src/main/java/org/apache/jcp/xml/dsig/internal/dom/XmlWriterToTree.java Tue Aug 26 18:56:00 2014
@@ -82,7 +82,7 @@ public class XmlWriterToTree implements
m_nextSibling.getParentNode().insertBefore(newElem, m_nextSibling);
}
else {
- m_currentNode.appendChild(newElem);
+ newElem = (Element)m_currentNode.appendChild(newElem);
}
m_nextSibling = null;
m_currentNode = newElem;