cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r924120 - /cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java
Date Wed, 17 Mar 2010 03:05:27 GMT
Author: dkulp
Date: Wed Mar 17 03:05:27 2010
New Revision: 924120

URL: http://svn.apache.org/viewvc?rev=924120&view=rev
Log:
Fix a potential ClassCastException

Modified:
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java?rev=924120&r1=924119&r2=924120&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java
(original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java
Wed Mar 17 03:05:27 2010
@@ -228,8 +228,10 @@ public class AttachmentDeserializer {
                 if (!ads.isCached()) {
                     ads.cache();
                 }
-            } else {
+            } else if (s.getInputStream() instanceof DelegatingInputStream) {
                 cache((DelegatingInputStream) s.getInputStream(), false);
+            } else {
+                //assume a normal stream that is already cached
             }
         }
     }



Mime
View raw message