You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by un...@apache.org on 2007/02/12 09:33:06 UTC

svn commit: r506371 - /incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java

Author: unrealjiang
Date: Mon Feb 12 00:33:06 2007
New Revision: 506371

URL: http://svn.apache.org/viewvc?view=rev&rev=506371
Log:
Fixed AttachmentDeserializer.readNext() throw out Null Pointer exception(CXF-418)

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

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java?view=diff&rev=506371&r1=506370&r2=506371
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/attachment/AttachmentDeserializer.java Mon Feb 12 00:33:06 2007
@@ -138,7 +138,10 @@
         String id = headers.getHeader("Content-ID", null);
         if (id != null && id.startsWith("<")) {
             id = id.substring(1, id.length() - 1);
+        } else {
+            return null;
         }
+        
         id = URLDecoder.decode(id.startsWith("cid:") ? id.substring(4) : id, "UTF-8");
         
         AttachmentImpl att = new AttachmentImpl(id);