You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@olingo.apache.org by "Sergey Beryozkin (JIRA)" <ji...@apache.org> on 2013/08/14 12:44:48 UTC
[jira] [Commented] (OLINGO-3) NPE guard for missing Accept headers
[ https://issues.apache.org/jira/browse/OLINGO-3?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13739511#comment-13739511 ]
Sergey Beryozkin commented on OLINGO-3:
---------------------------------------
CXF 3.0.0 will return null, I did not propagate the change to 2.7.x to avoid the code being broken unexpectedly :-)
> NPE guard for missing Accept headers
> ------------------------------------
>
> Key: OLINGO-3
> URL: https://issues.apache.org/jira/browse/OLINGO-3
> Project: Olingo
> Issue Type: Bug
> Components: odata2-core
> Environment: 1.0.0-SNAPSHOT
> Reporter: Aki Yoshida
> Priority: Minor
> Fix For: 1.0.0
>
> Attachments: odata-core-20130814.patch
>
>
> org.apache.olingo.odata2.core.rest.RestUtil's extractAcceptHeaders is not guarding against an NPE for the missing accept headers.
> cxf-2.7.x currently returns an empty list in this case, therefore it does not lead to an issue. However, the correct behavior is to return a null in this case.
> https://java.net/jira/browse/JAX_RS_SPEC-391?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=359530#action_359530
> Therefore, the above method should guard against an NPE for the acceptHeaders variable being null.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira