Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-2890

JSP error on <property> tag, when value is zero-sized array

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Cannot Reproduce
    • 2.0.14
    • 2.1.3
    • Plugin - Tags
    • None
    • Windows XP,

    Description

      If property in actions returns zero-sized array, like new Messages[]{}
      then Using <s:property> tag
      ...
      Messages : <s:property value="%

      {messages}

      "/>
      ...

      will throw Exception like this
      avax.servlet.ServletException: java.io.IOException: Stream closed
      org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:515)
      org.apache.struts2.dispatcher.FilterDispatcher.doFilter(FilterDispatcher.java:419)
      com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:118)
      com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:52)
      org.apache.struts2.dispatcher.ActionContextCleanUp.doFilter(ActionContextCleanUp.java:99)
      org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:164)
      org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
      org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
      org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:406)
      org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:359)
      org.springframework.security.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:109)
      org.springframework.security.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:83)
      org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:371)
      org.springframework.security.ui.SessionFixationProtectionFilter.doFilterHttp(SessionFixationProtectionFilter.java:67)
      org.springframework.security.ui.SpringSecurityFilter.doFilter(SpringSecurityFilter.java:53)
      org.springframework.security.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:371)
      org.springframework.security.ui.ExceptionTranslationFilter.doFilterHttp(ExceptionTranslationFilter.java:101)

      Attachments

        Activity

          People

            Unassigned Unassigned
            tt.kilew Taykalo Paul
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: