You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Steffen Morawietz (JIRA)" <de...@myfaces.apache.org> on 2007/03/04 14:53:50 UTC

[jira] Created: (MYFACES-1554) HtmlRendererUtils.selectContentType fails for generic content-type declaration

HtmlRendererUtils.selectContentType fails for generic content-type declaration
------------------------------------------------------------------------------

                 Key: MYFACES-1554
                 URL: https://issues.apache.org/jira/browse/MYFACES-1554
             Project: MyFaces Core
          Issue Type: Bug
          Components: General
    Affects Versions: 1.1.4
            Reporter: Steffen Morawietz
            Priority: Minor


We recently had a user with the accept-header set to "Accept = text/*, image/*, application/*, audio/*" which, according to the RFC (http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html), seems completely legal:

 " The asterisk "*" character is used to group media types into ranges, with "*/*" indicating all media types and "type/*" indicating all subtypes of that type. The media-range MAY include media type parameters that are applicable to that range. "

In this case HtmlRendererUtils failed to determine the content-type:

java.lang.IllegalArgumentException: ContentTypeList does not contain a supported content type: text/*, image/*, application/*, audio/*
at org.apache.myfaces.shared_impl.renderkit.html.HtmlRendererUtils.selectContentType(HtmlRendererUtils.java:1043)
at org.apache.myfaces.renderkit.html.HtmlRenderKitImpl.createResponseWriter(HtmlRenderKitImpl.java:126)
at javax.faces.webapp.UIComponentTag.setupResponseWriter(UIComponentTag.java:936)
at javax.faces.webapp.UIComponentTag.doStartTag(UIComponentTag.java:310)
at org.apache.myfaces.taglib.core.ViewTag.doStartTag(ViewTag.java:70)

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