You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2009/06/10 04:31:31 UTC

svn commit: r783181 - /cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJOutInterceptor.java

Author: dkulp
Date: Wed Jun 10 02:31:31 2009
New Revision: 783181

URL: http://svn.apache.org/viewvc?rev=783181&view=rev
Log:
Fix compile failure

Modified:
    cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJOutInterceptor.java

Modified: cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJOutInterceptor.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJOutInterceptor.java?rev=783181&r1=783180&r2=783181&view=diff
==============================================================================
--- cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJOutInterceptor.java (original)
+++ cxf/branches/2.0.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/saaj/SAAJOutInterceptor.java Wed Jun 10 02:31:31 2009
@@ -29,7 +29,6 @@
 import javax.xml.soap.SOAPException;
 import javax.xml.soap.SOAPMessage;
 import javax.xml.soap.SOAPPart;
-import javax.xml.stream.XMLStreamException;
 import javax.xml.stream.XMLStreamWriter;
 
 
@@ -93,17 +92,13 @@
         } else {
             //as the SOAPMessage already has everything in place, we do not need XMLStreamWriter to write
             //anything for us, so we just set XMLStreamWriter's output to a dummy output stream.         
-            try {
-                XMLStreamWriter dummyWriter = StaxUtils.createXMLStreamWriter(new OutputStream() {
-                        public void write(int b) throws IOException {
-                        }
-                        public void write(byte b[], int off, int len) throws IOException {
-                        }                        
-                    });
-                message.setContent(XMLStreamWriter.class, dummyWriter);
-            } catch (XMLStreamException e) {
-                // do nothing
-            }
+            XMLStreamWriter dummyWriter = StaxUtils.createXMLStreamWriter(new OutputStream() {
+                    public void write(int b) throws IOException {
+                    }
+                    public void write(byte b[], int off, int len) throws IOException {
+                    }                        
+                });
+            message.setContent(XMLStreamWriter.class, dummyWriter);
         }
         //must turn off mtom when using SAAJ so binary is properly inlined
         message.put(org.apache.cxf.message.Message.MTOM_ENABLED, false);