cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r897944 - /cxf/trunk/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java
Date Mon, 11 Jan 2010 17:00:25 GMT
Author: dkulp
Date: Mon Jan 11 17:00:25 2010
New Revision: 897944

URL: http://svn.apache.org/viewvc?rev=897944&view=rev
Log:
Some versions of Sun's jaxp throw and exception, they don't return null.

Modified:
    cxf/trunk/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java

Modified: cxf/trunk/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java
URL: http://svn.apache.org/viewvc/cxf/trunk/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java?rev=897944&r1=897943&r2=897944&view=diff
==============================================================================
--- cxf/trunk/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java (original)
+++ cxf/trunk/common/common/src/main/java/org/apache/cxf/staxutils/StaxUtils.java Mon Jan
11 17:00:25 2010
@@ -1088,7 +1088,13 @@
             
             XMLInputFactory factory = getXMLInputFactory();
             try {
-                XMLStreamReader reader = factory.createXMLStreamReader(source);
+                XMLStreamReader reader = null;
+            
+                try {
+                    reader = factory.createXMLStreamReader(source);
+                } catch (UnsupportedOperationException e) {
+                    //ignore
+                }
                 if (reader == null && source instanceof StreamSource) {
                     //createXMLStreamReader from Source is optional, we'll try and map it
                     StreamSource ss = (StreamSource)source;



Mime
View raw message