chemistry-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From f...@apache.org
Subject svn commit: r1516935 - /chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/XMLConverter.java
Date Fri, 23 Aug 2013 17:15:30 GMT
Author: fmui
Date: Fri Aug 23 17:15:30 2013
New Revision: 1516935

URL: http://svn.apache.org/r1516935
Log:
avoid invalid XML

Modified:
    chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/XMLConverter.java

Modified: chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/XMLConverter.java
URL: http://svn.apache.org/viewvc/chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/XMLConverter.java?rev=1516935&r1=1516934&r2=1516935&view=diff
==============================================================================
--- chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/XMLConverter.java
(original)
+++ chemistry/opencmis/trunk/chemistry-opencmis-commons/chemistry-opencmis-commons-impl/src/main/java/org/apache/chemistry/opencmis/commons/impl/XMLConverter.java
Fri Aug 23 17:15:30 2013
@@ -389,6 +389,10 @@ public final class XMLConverter {
 
         writer.writeStartElement(namespace, TAG_TYPE);
         writer.writeNamespace(PREFIX_XSI, NAMESPACE_XSI);
+        String prefix = writer.getPrefix(namespace);
+        if (prefix != null) {
+            writer.writeNamespace(prefix, namespace);
+        }
 
         if (source.getBaseTypeId() == BaseTypeId.CMIS_DOCUMENT) {
             writer.writeAttribute(PREFIX_XSI, NAMESPACE_XSI, "type", PREFIX_CMIS + ":" +
ATTR_DOCUMENT_TYPE);



Mime
View raw message