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 2011/02/07 23:15:24 UTC

svn commit: r1068177 - in /cxf/branches/2.3.x-fixes: ./ rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalConduit.java

Author: dkulp
Date: Mon Feb  7 22:15:24 2011
New Revision: 1068177

URL: http://svn.apache.org/viewvc?rev=1068177&view=rev
Log:
Merged revisions 1068173 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1068173 | dkulp | 2011-02-07 17:12:14 -0500 (Mon, 07 Feb 2011) | 2 lines
  
  [CXF-3253] Make sure local conduit uses the correct output stream to
  launch the destination.
........

Modified:
    cxf/branches/2.3.x-fixes/   (props changed)
    cxf/branches/2.3.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalConduit.java

Propchange: cxf/branches/2.3.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.3.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalConduit.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.3.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalConduit.java?rev=1068177&r1=1068176&r2=1068177&view=diff
==============================================================================
--- cxf/branches/2.3.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalConduit.java (original)
+++ cxf/branches/2.3.x-fixes/rt/transports/local/src/main/java/org/apache/cxf/transport/local/LocalConduit.java Mon Feb  7 22:15:24 2011
@@ -61,6 +61,8 @@ public class LocalConduit extends Abstra
             // prepare the stream here
             CachedOutputStream stream = new CachedOutputStream();
             message.setContent(OutputStream.class, stream);
+            //save the original stream
+            message.put(CachedOutputStream.class, stream);
         }
     }
 
@@ -87,7 +89,10 @@ public class LocalConduit extends Abstra
         transportFactory.copy(message, copy);
         MessageImpl.copyContent(message, copy);
         
-        CachedOutputStream stream = (CachedOutputStream)message.getContent(OutputStream.class);
+        OutputStream out = message.getContent(OutputStream.class);
+        out.flush();
+        
+        CachedOutputStream stream = message.get(CachedOutputStream.class);
         copy.setContent(InputStream.class, stream.getInputStream());
 
         // Create a new incoming exchange and store the original exchange for the response