You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Benjamin Coiffe (JIRA)" <ji...@apache.org> on 2008/05/25 18:07:55 UTC

[jira] Commented: (CXF-1607) NPE when receiving a message containing attachement (using dynamic client).

    [ https://issues.apache.org/jira/browse/CXF-1607?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599696#action_12599696 ] 

Benjamin Coiffe commented on CXF-1607:
--------------------------------------

Please read CXF-1603 instead of CXF-1607.

> NPE when receiving a message containing attachement (using dynamic client).
> ---------------------------------------------------------------------------
>
>                 Key: CXF-1607
>                 URL: https://issues.apache.org/jira/browse/CXF-1607
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.1.1
>            Reporter: Benjamin Coiffe
>             Fix For: 2.1.1
>
>
> The WSDL for this service is attached on CORE-1603, the operation invoked is convertMime(in soserv.converter.types.ConvertMime convertMime, in byte[] mimeAttachment, out byte[] mimeAttachment, out soserv.converter.types.ConvertMimeResponse convertMimeResponse).
> For some reason, in the HolderInInterceptor, the list of Holder is [null,null]....
> The code below does the trick (at least for that web service):
>  if (client) {
>             List<Holder> outHolders = CastUtils.cast((List)message.getExchange()
>                 .getOutMessage().get(CLIENT_HOLDERS));
>             for (MessagePartInfo part : parts) {
>                 if (part.getIndex() != 0 && part.getTypeClass() != null) {
>                     Holder holder = (Holder)outHolders.get(part.getIndex() - 1);
>                     if (holder != null) {
>                         holder.value = inObjects.get(part);
>                         inObjects.put(part, holder);
>                     }
>                 }
>             }
>         } 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.